Shindig in 2 hours

7,009 views
6,720 views

Published on

In 2 hours, we discuss about apache shindig and how to integrate shindig in eXo Platform production. The presentation lay-out in a simple way to understand about shindig, why and how using shindig as a part of developing product. Since shindig is a best implementation of OpenSocial then know about it and find the way to apply it is needed. In eXo Platform now, shindig is being used as Gadget Container/Server and the based Container to enable eXo Social fully support OpenSocial standard. Short but clear about shindig, hope it helps.

Published in: Technology
1 Comment
6 Likes
Statistics
Notes
No Downloads
Views
Total views
7,009
On SlideShare
0
From Embeds
0
Number of Embeds
24
Actions
Shares
0
Downloads
158
Comments
1
Likes
6
Embeds 0
No embeds

No notes for slide

Shindig in 2 hours

  1. 1. SHINDIG IN 2 HOURS [email_address] Social team
  2. 3. <ul><li>Apache Shindig : </li></ul><ul><li>- Introduction </li></ul><ul><li>- Architecture </li></ul><ul><li>Shindig integration (eXo) </li></ul><ul><li>Objective: 3W </li></ul>In 2 hours ...
  3. 4. Shindig Introduction
  4. 6. Apache Shindig (Introduction)
  5. 7. Apache Shindig (Introduction)
  6. 8. Apache Shindig (Introduction)
  7. 9. Apache Shindig (Introduction)
  8. 10. Apache Shindig (Introduction)
  9. 11. Apache Shindig (Introduction)
  10. 12. Apache Shindig (Introduction)
  11. 13. Apache Shindig What is shindig? - OpenSocial container ->start hosting OpenSocial apps quickly by: + Providing the code to render gadgets + Open Social API, RESTful, RPC protocol services - Java and PHP Goal Lauch a new container in under an hour's worth of work .
  12. 14. <ul><li>Version Release OpenSocial </li></ul><ul><li>3.0.0 </li></ul><ul><li>2.0.3 01/Dec/10 </li></ul><ul><li>2.0.2 30/Oct/10 </li></ul><ul><li>2.0.0 07/Sep/10 </li></ul><ul><li>2.0.0-RC2 10/Aug/10 </li></ul><ul><li>1.1-BETA5 23/Nov/09 0.9 </li></ul><ul><li>1.0.1 10/May/10 0.8 </li></ul><ul><li>1.0 19/Jun/09 </li></ul>Apache Shindig (History) Nov 2007
  13. 15. Apache Shindig (In Production)
  14. 16. Apache Shindig. Why Use? • Strong Open Source community • High quality production-ready code • Used by: hi5, orkut, iGoogle, Netlog, Hyves … • Synchronized with specification • Language neutral (Java, PHP, ...)
  15. 17. Apache Shindig (Getting Started-Java) http://shindig.apache.org/getting-started.html - Check out code svn co http://svn.apache.org/repos/asf/incubator/shindig/trunk - Build & Run (Jetty Server) mvn clean install mvn -Prun - Run (tomcat server) http://localhost:8080/container/sample1.html http://localhost:8080/social/rest/people/canonical/@self?format=xml
  16. 18. Shindig Architecture
  17. 19. • Gadget Server Parses gadget XML, renders as HTML/JS/CSS • OpenSocial Data Server - Plugs into social graph data - RESTful, RPC protocol services • Downloaded JavaScript libraries Core gadgets, OpenSocial client JavaScript environment Shindig Architecture (Components)
  18. 20. Apache Shindig (APIs – Entry Points) - OS API renderGadget() req.send() req..requestCreateActivity() - REST API ..social/rest/people/... ..social/rest/activities/...
  19. 21. • Shindig Client and Server Components • Gadget Server • Social Data Server Shindig Architecture
  20. 22. • Shindig Client and Server Components • Gadget Server • Social Data Server Shindig Architecture
  21. 23. Shindig Architecture (Components)
  22. 24. Shindig Architecture (Server Comps) - _Servlets are entry points to take calls from client side.
  23. 25. Shindig Architecture (How It Works?) Req TYPE FETCH_PEOPLE : Get Person data FETCH_PERSON_APP_DATA : Get the data attributes for a person UPDATE_PERSON_APP_DATA : update attributes of a person FETCH_ACTIVITIES : Get List of activities for a Particular Person CREATE_ACTIVITY : create Activity associated with a Person
  24. 26. • Shindig Client and Server Components • Gadget Server • Social Data Server Shindig Architecture
  25. 27. Gadget Server - Gadget Container JavaScript : JavaScript for general gadget functionality. - Gadget Rendering Server : to render the gadget XML into HTML. Gadget Gadget Server Social Data Server HTML
  26. 28. Gadget Rendering in Flow
  27. 29. • Shindig Client and Server Components • Gadget Server • Social Data Server Shindig Architecture
  28. 30. Social Data Server People Relationships Activities
  29. 31. Social Data Server - OpenSocial Container JavaScript : JavaScript environment that provides OpenSocial specific functionality (Profiles, Relationships, Activities). - OpenSocial Data Server : with extension points so others can connect it to their own backends . Gadget Gadget Server Social Data Server JSON
  30. 32. Social Data Server http://rollerweblogger.org/roller/entry/shindig_java_internals_diagram_updated
  31. 33. Social Data Server
  32. 34. Shindig Integration
  33. 35. <ul><li>Utilize existing Open Source container code. </li></ul><ul><li>Wants Gadgets </li></ul><ul><li>Wants Social features : Profiles, Relationships, Activities </li></ul>Integration. Why?
  34. 36. Integration. How? - Shindig Implementation : Java, PHP … - Gadget Server, Social Data Server
  35. 37. Integration Render gadget OpenSocial Container (Social Data Server)
  36. 38. • Customize sample comtainer (Gadget Container) • Implement Interfaces – People, Friends, Activities (Social Server) • Write Guice Modules (binding) • Add mapping information to web.xml (servlets, filters, guices- modules … ) • Add more SecurityTokenDecoder, etc. (Enabling OAuth support) Integration (SUMMARIZE)
  37. 39. • Customize sample comtainer (Gadget Container) • Implement Interfaces – People, Friends, Activities (Social Server) • Write Guice Modules (binding) • Add mapping information to web.xml (servlets, filters, guices- modules … ) • Add more SecurityTokenDecoder, etc. (Enabling OAuth support) Integration
  38. 40. • Customize sample comtainer (Gadget Container) • Implement Interfaces – People, Friends, Activities (Social Server) • Write Guice Modules (binding) • Add mapping information to web.xml (servlets, filters, guices- modules … ) • Add more SecurityTokenDecoder, etc. (Enabling OAuth support) Integration
  39. 41. - People Service public class ExoPeopleService extends ExoService implements PersonService, AppDataService { public Future<RestfulCollection<Person>> getPeople(...) {} public Future<Person> getPerson(...) {} } - Activitiy Service public class ExoActivityService extends ExoService implements ActivityService { public Future<RestfulCollection<Activity>> getActivities (...) {} public Future<Void> createActivity (...) {} } Copyright 2010 eXo Platform SAS Integration (Implement Interfaces)
  40. 42. • Customize sample comtainer (Gadget Container) • Implement Interfaces – People, Friends, Activities (Social Server) • Write Guice Modules (binding) • Add mapping information to web.xml (servlets, filters, guices- modules … ) • Add more SecurityTokenDecoder, etc. (Enabling OAuth support) Integration
  41. 43. public class ExoSocialApiGuiceModule extends AbstractModule { @Override protected void configure() { bind(PersonService. class ).to(ExoPeopleService. class ); bind(AppDataService. class ).to(ExoPeopleService. class ); bind(ActivityService. class ).to(ExoActivityService. class ); bind(Person. class ).to(ExoPersonImpl. class ); } } Copyright 2010 eXo Platform SAS Integreation (Guice Module)
  42. 44. • Customize sample comtainer (Gadget Container) • Implement Interfaces – People, Friends, Activities (Social Server) • Write Guice Modules (binding) • Add mapping information to web.xml (servlets, filters, guices- modules … ) • Add more SecurityTokenDecoder, etc. (Enabling OAuth support) Integration
  43. 45. webapp/opensocial/src/main/webapp/WEB-INF/web.xml <context-param> <param-name>guice-modules</param-name> <param-value> org.exoplatform.social.opensocial.ExoSocialApiGuiceModule </param-value> </context-param> Copyright 2010 eXo Platform SAS Integration (Config in Web.xml)
  44. 46. Re-Cap
  45. 47. - OpenSource implementation of OpenSocial & Gadgets standard (Java, PHP) - Client and Server side (Container, REST, OpenSocial APIs …) - Java version: Servlet stack - Multiple entry points for various kinds of calls (servlets) - Others: Image Resizer, Content Rewriter/Compressor ... Copyright 2010 eXo Platform SAS Re-Cap
  46. 48. Copyright 2010 eXo Platform SAS Why not?
  47. 49. Home Page: http://shindig.apache.org/ Downloads: http://shindig.apache.org/download/index.html Mailing Lists: http://shindig.apache.org/mail-lists.html Source Code: http://svn.apache.org/repos/asf/shindig/ Issue Tracking: https://issues.apache.org/jira/browse/SHINDIG Wiki: http://cwiki.apache.org/confluence/display/SHINDIG/ Copyright 2010 eXo Platform SAS Resources
  48. 50. Thank you!

×