31
It's an OpenSocial Generation A year’s worth of growth, tips, and tricks Raymond Chan - November 19, 2008

RockYou at Girls in Tech Developer Forum

  • View
    2.185

  • Download
    0

Embed Size (px)

DESCRIPTION

RockYou's Raymond Chan gave an informative presentation about OpenSocial at the Girls in Tech Developer Summit November 19, 2008 in San Francisco. Raymond gave a short history of OpenSocial and a lot of detailed information on coding for OpenSocial.

Citation preview

Page 1: RockYou at Girls in Tech Developer Forum

It's an OpenSocial GenerationA year’s worth of growth, tips, and tricks

Raymond Chan - November 19, 2008

Page 2: RockYou at Girls in Tech Developer Forum

2

What is RockYou?

Mission – “To engage the world through social applications”

Leading developer across all major social networks and platforms– MySpace, Facebook, hi5, orkut, Friendster, Bebo, Xiaonei…

Large Social Application Reach (excluding profile widgets)

– Over 90+ million uniques (monthly)

RockYou! Team– ~80 employees across engineering, product, business

development and sales

Page 3: RockYou at Girls in Tech Developer Forum

3

Overview

OpenSocial turns one– Reviewing a year of enormous growth

What is OpenSocial?– Overview of the community process– Example applications– Coding a simple “Hello World” app

Developer tips and lessons learned– OpenSocial cross-container tips– Using analytics to scale – a brief overview of RYStatz

Page 4: RockYou at Girls in Tech Developer Forum

4

What’s so interesting about OpenSocial?

Page 5: RockYou at Girls in Tech Developer Forum

5

What’s so interesting about OpenSocial?

Later that year…

Page 6: RockYou at Girls in Tech Developer Forum

6Taken from OpenSocial “State of

the Union” presentation

Page 7: RockYou at Girls in Tech Developer Forum

7

Taken from OpenSocial “State of the Union” presentation

Page 8: RockYou at Girls in Tech Developer Forum

8

A Year of Enormous Growth

A resounding success across the OpenSocial ecosystem– 315m+ app installs– 85m+ daily canvas views

RockYou’s Success– Launched a portfolio of applications: self expression,

communication / messaging, dating, virtual pets– Installed over 55m times– Material to driving RockYou’s global reach of over 90m monthly

users

Page 9: RockYou at Girls in Tech Developer Forum

9

What is OpenSocial?

It’s a specification– Set of standards for sharing social data and building social

applications on the web– Defines a set of social APIs and standards– Built upon open standards, and utilizes open-source philosophies

It’s a community– Containers (social sites), application developers, anybody who is

interested– Open-source implementations (Apache Shindig)– The OpenSocial Foundation

Page 10: RockYou at Girls in Tech Developer Forum

10

Exercising the Open Source Model

“The OpenSocial Specification is constantly evolving.  The basic idea behind our process is to treat the spec like an open source software project, following some basic tenets from the Apache Software Foundation:– Participation is open to anyone– Decisions are made on the spec list (not behind closed doors)– All proceedings are captured in a public archive

– Individuals represent themselves, not companies”From www.opensocial.org

Page 11: RockYou at Girls in Tech Developer Forum

11

So what can we build with OpenSocial?

Page 12: RockYou at Girls in Tech Developer Forum

12

Application Spotlight – Super Pets!

Highly-engaging virtual pets – users adopt and customize pets, then accessorize them and participate in casual and competitive gaming

Page 13: RockYou at Girls in Tech Developer Forum

13

Application Spotlight – Super Pets!

Pet customizations / accessories

•Virtual Currency / Digital Economy

•Battling / Casual Gaming

Page 14: RockYou at Girls in Tech Developer Forum

14

Application Spotlight – Emote

RockYou’s most widely-distributed self expression application

Page 15: RockYou at Girls in Tech Developer Forum

15

Writing a social “Hello World” app

Easy to get started– Basic apps composed of HTML + javascript– Some containers do not even require hosting (just paste in the

code)

Basic concepts– Application gadget XML– Views – profile, canvas

Page 16: RockYou at Girls in Tech Developer Forum

16

Example Gadget XML

<?xml version="1.0" encoding="UTF-8" ?><Module> <ModulePrefs title="Hello World!" author_email="[email protected]"> <Require feature="opensocial-0.8" /> </ModulePrefs> <Content type="html" view="profile"> <![CDATA[ Hello, Profile! ]]> </Content> <Content type="html" view="canvas"> <![CDATA[ Hello, Canvas! ]]> </Content></Module>

Page 17: RockYou at Girls in Tech Developer Forum

17

ModulePrefs

<ModulePrefs title="Hello World!" author_email="[email protected]"> <Require feature="opensocial-0.8" /> </ModulePrefs>

Page 18: RockYou at Girls in Tech Developer Forum

18

Content element per view

<Content type="html" view="profile"> <![CDATA[ <!–- add html and javascript here, as if this were a body section of a web page -->

]]> </Content>

Page 19: RockYou at Girls in Tech Developer Forum

19

Making “Hello World!” a bit more social

<script type="text/javascript">

function request() {var idspec = opensocial.newIdSpec({ "userId" : "OWNER", "groupId" : "FRIENDS" });var req = opensocial.newDataRequest();req.add(req.newFetchPersonRequest(opensocial.IdSpec.PersonId.OWNER), "get_owner");req.add(req.newFetchPeopleRequest(idspec), "get_friends");req.send(response);

};

function response(dataResponse) {var owner = dataResponse.get('get_owner').getData();var friends = dataResponse.get('get_friends').getData(); var html = 'Friends of ' + owner.getDisplayName();html += ':<br><ul>';friends.each(function(person) { html += '<li>' + person.getDisplayName() + '</li>';});html += '</ul>';document.getElementById('message').innerHTML = html;

};

// Execute the request function when the application is finished loading. gadgets.util.registerOnLoadHandler(request);

</script>

<div id="message"> </div>

From OpenSocial Developer’s Guide

Page 20: RockYou at Girls in Tech Developer Forum

20

Developer Tips and Lessons Learned

OpenSocial == Cross-container development

Importance of messaging in social apps

Dealing with scale

Importance of effective analytics for success

Page 21: RockYou at Girls in Tech Developer Forum

21

Cross-Container Development Tips

Design flexible layouts to accommodate different view sizes

Gracefully handle differences in how containers handle user information– Default fields, querying by user ids (0.7), page sizes / ordering

Take time to understand how messaging channels are implemented on different containers– User experience varies greatly site to site– Wide range of user preferences across social networks

Page 22: RockYou at Girls in Tech Developer Forum

22

Cross-Container Development Tips

OpenSocial applications have proven to be portable, even to Facebook

Canvas pages shared between OpenSocial and Facebook– Use common-sense encapsulation and abstraction

Facebook iframe application using XFBML/FBJS

Page 23: RockYou at Girls in Tech Developer Forum

23

Scaling social apps

Good problem to have, bad problem to deal with…

0

10

20

30

40

50

1 3 5 7 9 11 13 15 17 19 21 23

Months (1)

Facebook platform launch

Page 24: RockYou at Girls in Tech Developer Forum

24

Scaling social apps

If you have lots of money, build everything yourself…

Otherwise…

Page 25: RockYou at Girls in Tech Developer Forum

25

Gratuitous screenshot of app stats

Page 26: RockYou at Girls in Tech Developer Forum

26

Randomized trials for testing application features

Running two profile designs simultaneously; users grouped by their network ids

Page 27: RockYou at Girls in Tech Developer Forum

27

Diagnosing / monitoring complex systems

App activity measure

Page 28: RockYou at Girls in Tech Developer Forum

28

Diagnosing / monitoring complex systems

Overlay deployments

Page 29: RockYou at Girls in Tech Developer Forum

29

When good sites go bad

Important to understand your app’s dependencies (yellow line is API call failures)

Page 30: RockYou at Girls in Tech Developer Forum

30

When good sites go bad

Effect on application functionality

Page 31: RockYou at Girls in Tech Developer Forum

31

fin

Questions / comments?

Contact: Raymond Chan ([email protected])