52
International PHP Conference 17. Nov. 2009 | Karlsruhe Frank Ruske

Vorstellung Open Social Ipc 2009

  • Upload
    fruske

  • View
    473

  • Download
    1

Embed Size (px)

Citation preview

Page 1: Vorstellung Open Social Ipc 2009

International PHP Conference17. Nov. 2009 | KarlsruheFrank Ruske

Page 2: Vorstellung Open Social Ipc 2009

© MAYFLOWER GmbH 2009

2 OpenSocial

F rank Rus ke

❙>10 J ahre Erfahrung in der Softwareentwicklung

❙Seit März 2009 Mitarbeiter bei Mayflower

❙Autor für das PHP-Magazin

Page 3: Vorstellung Open Social Ipc 2009

Was ist das Objekt?

Page 4: Vorstellung Open Social Ipc 2009

Was ist das Ziel?

Page 5: Vorstellung Open Social Ipc 2009

Wie kann das Objekt geshared werden?

Page 6: Vorstellung Open Social Ipc 2009

4.294.967.296

340.282.366.920.938.463.463.374.607.431.768.211.456

665.570.793.348.866.943.898.599 pro Quadratkilometer665.570.793.348.866.943.898.599 pro Quadratkilometerca. 667.000.000.000.000.000 pro Quadratmillimeterca. 667.000.000.000.000.000 pro Quadratmillimeter

Page 7: Vorstellung Open Social Ipc 2009

Was ist die Belohnung für eine Anmeldung?

Page 8: Vorstellung Open Social Ipc 2009

Business Model?

Page 9: Vorstellung Open Social Ipc 2009

Wie können wir Objekte sozialisieren ohne ein

weiteres Social Network zu erstellen?

Page 10: Vorstellung Open Social Ipc 2009
Page 11: Vorstellung Open Social Ipc 2009
Page 12: Vorstellung Open Social Ipc 2009
Page 13: Vorstellung Open Social Ipc 2009
Page 14: Vorstellung Open Social Ipc 2009

a common open set of API's for building

social applications across multiple sites

Page 15: Vorstellung Open Social Ipc 2009
Page 16: Vorstellung Open Social Ipc 2009
Page 17: Vorstellung Open Social Ipc 2009
Page 18: Vorstellung Open Social Ipc 2009

Gadget (XML)Clientseitig: J avaScript, HTML

und CSS

ContainerServerseitig: RESTfull API, J SON

RPC (optional)

Page 19: Vorstellung Open Social Ipc 2009

GrundfunktionenPeople,Friends,Activities,

Persistence

Page 20: Vorstellung Open Social Ipc 2009

BenutzergruppenViewerOwnerFriend

Page 21: Vorstellung Open Social Ipc 2009
Page 22: Vorstellung Open Social Ipc 2009

http://www.frank-ruske.com/ipc/hello_world.xml

OpenS oc ia l applic ation „Hello w orld“

Page 23: Vorstellung Open Social Ipc 2009
Page 24: Vorstellung Open Social Ipc 2009
Page 25: Vorstellung Open Social Ipc 2009
Page 26: Vorstellung Open Social Ipc 2009

http://www.frank-ruske.com/ipc/show_friends_final.xml

Page 27: Vorstellung Open Social Ipc 2009
Page 28: Vorstellung Open Social Ipc 2009
Page 29: Vorstellung Open Social Ipc 2009

http://www.frank-ruske.com/ipc/activity.xml

Page 30: Vorstellung Open Social Ipc 2009
Page 31: Vorstellung Open Social Ipc 2009

http://www.frank-ruske.com/ipc/save_data.xml

Page 32: Vorstellung Open Social Ipc 2009

gadgets.io.makeRequest()

Page 33: Vorstellung Open Social Ipc 2009

Apache Shindig

Inc ubator s e it November 2007

Page 34: Vorstellung Open Social Ipc 2009
Page 35: Vorstellung Open Social Ipc 2009

http://shindig.local/gadgets/files/samplecontainer/samplecontainer.htmlhttp://shindig.local/gadgets/files/samplecontainer/examples/SocialHelloWorld.xml

Page 36: Vorstellung Open Social Ipc 2009

http://www.frank-ruske.com/ipc/activity.xml

Page 37: Vorstellung Open Social Ipc 2009
Page 38: Vorstellung Open Social Ipc 2009

RE S T / PE OPL E/people/{guid}/@all

Alle Leute mit Verbindungen zum User {guid}

/people/{guid}/@friendsAlle Freunde vom Benutzer {guid}

/people/{guid}/@selfProfil vom Benutzer {guid}

/people/@me/@selfProfil des Viewers

Page 39: Vorstellung Open Social Ipc 2009

Freunde von „J ane Doe“

http://shindig.local/social/rest/people/jane.doe/@friends

Page 40: Vorstellung Open Social Ipc 2009

RE S T / AC T IVIT IE S/activities/{guid}/@self

Liste mit Aktivitäten des User {guid}

/activities/{guid}/@friendsListe mit Aktivitäten der Freunde des User {guid}

Page 41: Vorstellung Open Social Ipc 2009

Aktivität von „John.doe“

http://shindig.local/social/rest/activities/john.doe/@self

Page 42: Vorstellung Open Social Ipc 2009

RE S T / PE RS IS T E NC E/appdata/{guid}/@self/{appid}

Alle App spezifischen Daten für den User {guid}

/appdata/{guid}/@friends/{appid}Alle App spezifischen Daten für die Freunde des Users

Page 43: Vorstellung Open Social Ipc 2009

RE S T / Additiona l Parameters

/format={format}Format der Rückgabe (ATOM, J SON, XML)

/fields={field+}Die Felder die zurück gegeben werden sollen

/startPage={startPage}Paginator

/count={count}Paginator – Anzahl von Items

Page 44: Vorstellung Open Social Ipc 2009

Additional Parameters

http://shindig.local/social/rest/activities/john.doe/@self?format=XML

Page 45: Vorstellung Open Social Ipc 2009

C onta iner implementieren:

1.) PHP Interfac es implementieren:ActivityService, PersonService, AppDataService,

MessagesService, AlbumService, MediaItemService

2.) Apache Shindig konfigurieren

Page 46: Vorstellung Open Social Ipc 2009

1.) PHP Interfac es implementieren:class JsonDbOpensocialService implements ActivityService, PersonService, AppDataService, MessagesService, AlbumService, MediaItemService {...}

http://svn.apache.org/repos/asf/incubator/shindig/trunk/php/src/social/sample/J sonDbOpensocialService.php

Page 47: Vorstellung Open Social Ipc 2009

2.) S hindig konfigurieren

http://svn.apache.org/repos/asf/incubator/shindig/trunk/php/config/container.php

Page 48: Vorstellung Open Social Ipc 2009

PartuzaOpenSocial / Social Network Beispielseite

Kommuniziert mit Apache Shindig

Implementiert in PHP

Page 49: Vorstellung Open Social Ipc 2009

1.) PHP Interfaces implementieren:class PartuzaService implements ActivityService, PersonService,

AppDataService, MessagesService, AlbumService, MediaItemService {...}

http://code.google.com/p/partuza/source/browse/trunk/Shindig/PartuzaService.php

Page 50: Vorstellung Open Social Ipc 2009

2.) Shindig konfigurieren

http://svn.apache.org/repos/asf/incubator/shindig/trunk/php/config/container.php

Page 51: Vorstellung Open Social Ipc 2009

Links und Referenzenunter

www.frank-ruske.com/ipc09

Page 52: Vorstellung Open Social Ipc 2009

Vie len Dank für Ihre Aufmerks amkeit!

ReferentFrank RuskeMayflower GmbHPleichertorstr. 297070 Würzburg+49 (931) 35 9 65 - [email protected]