RESTifying WS-* Services  A Case Study in  RFID (Radio Frequency IDentification) Dominique Guinard SAP Research & ETH Zuri...
Today’s Menu <ul><li>Background: </li></ul><ul><ul><li>The global RFID network in a nutshell </li></ul></ul><ul><ul><li>Wh...
BACKGROUND <ul><li>RFID? EPC? EPC Network? </li></ul><ul><li>[ www.flickr.com/photos/docman ] </li></ul>
The EPC Network in a Nutshell
MOTIVATION <ul><li>REST and RFID? What do we want to achieve? </li></ul><ul><li>[www.flickr.com/photos/moragcasey/] </li><...
Bringing the EPC Network to the Web? <ul><li>WS-*  are adequate for business integration: </li></ul><ul><ul><li>with an ER...
ARCHITECTURE <ul><li>Resource design, RESTful framework, implementation </li></ul><ul><li>[www.flickr.com/photos/julianble...
Design: Addressability & Connectedness <ul><li>Resources: </li></ul><ul><ul><li>Locations, Readers, Tagged objects (EPC), ...
Design: Wait, the EPCIS is not Hierachical! <ul><li>The EPCIS data isn‘t really hierachical: </li></ul><ul><ul><li>E.g. an...
Design: Representations <ul><li>RESTful APIs should offer several resprentations: </li></ul><ul><ul><li>XML for respecting...
Implementation: Which REST Framework?  <ul><li>Major (Java, JAX-RS) frameworks: </li></ul><ul><ul><li>Apache CFX, RestEasy...
Implementation: Component Architecture <ul><li>RESTful EPCIS as a independent component: </li></ul><ul><ul><li>+ Can be pl...
Benchmarking REST vs WS-*
DEMONSTRATION <ul><li>A Mashup Tool for the Web of Things </li></ul><ul><li>[ www.flickr.com/photos/lpettinati ] </li></ul>
Demo: EPC Mashup Dashboard <ul><li>A Javascript (Google Web Toolkit) mashup for: </li></ul><ul><ul><li>Product managers to...
Dominique Guinard guinard.org SAP Research / ETH Zurich dominique.guinard at sap.com Mathias Mueller diuf.unifr.ch/softeng...
Backup
The EPC Network in a Nutshell <ul><li>EPC (Electronic Product Code) Network: </li></ul><ul><ul><li>Creating an “Internet o...
Upcoming SlideShare
Loading in …5
×

RESTifying WS-* Services: Case Study in RFID

1,868 views
1,785 views

Published on

RESTifying WS-* Services: Case Study in RFID

Published in: Business, Technology
0 Comments
2 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
1,868
On SlideShare
0
From Embeds
0
Number of Embeds
25
Actions
Shares
0
Downloads
63
Comments
0
Likes
2
Embeds 0
No embeds

No notes for slide
  • www.webofthings.com
  • Where we started, a quick overview of our first trials to integrate sensor networks to business applications. A few guidelines on how to make sensor nodes first class citizens of the Web. Our implementation of these guidelines on the Sun SPOT plateform, including the video of a business use case we implemented using the RESTful Sun SPOTs.
  • The ``what&apos;&apos;: what tagged products (EPCs) were read. The ``when&apos;&apos;: at what time were the products read. The ``where&apos;&apos;: where were the products read, in terms of Business Location (e.g. ``Floor B&apos;&apos;). The ``who&apos;&apos;: what readers (Read Point) recorded this trace. The ``which&apos;&apos;: what was the business context (Business Step) recording the trace (e.g. ``Shipping&apos;&apos;). Set of standards: Creating an « Internet of Things » The EPCIS is the information service: Sharing of RFID data. Exposes as standard WS-* interface Serveral EPCIS vendors: SAP AII (Auto-Id Infrastructure) IBM InfoSphere Fosstrak EPCIS (open source) Oracle Oracle Sensor Data Manager
  • According to expert of the domain (benchmarking made at SAP): Apache CFX According to me: Jersey
  • EPCIS: Fosstrak, SAP AII REST Fwork: jersey Atom: Abdera Container: Apache tomcat / Grizzly / Glassfish v3.
  • Yes, cool! But actually: Warning!!!! -&gt; We could really optimize WS-* services to perform way better (caching the WSDL, compressing the data). Still, these results are nicely surprising! Hem actually we could also optimize REST services as well (compressing and …. caching!!!!)
  • Test it on epcmashup.webofthings.com
  • Find all the links and resources mentionned in this talk on: http://delicious.com/misterdom/RESTfulEPCIS
  • RESTifying WS-* Services: Case Study in RFID

    1. 1. RESTifying WS-* Services A Case Study in RFID (Radio Frequency IDentification) Dominique Guinard SAP Research & ETH Zurich Mathias Mueller University of Fribourg 167
    2. 2. Today’s Menu <ul><li>Background: </li></ul><ul><ul><li>The global RFID network in a nutshell </li></ul></ul><ul><ul><li>Why RESTfying it? </li></ul></ul><ul><li>RESTification process / implementation </li></ul><ul><li>Demonstration </li></ul>[ flickr.com/photos/lessio/1346732230/ ]
    3. 3. BACKGROUND <ul><li>RFID? EPC? EPC Network? </li></ul><ul><li>[ www.flickr.com/photos/docman ] </li></ul>
    4. 4. The EPC Network in a Nutshell
    5. 5. MOTIVATION <ul><li>REST and RFID? What do we want to achieve? </li></ul><ul><li>[www.flickr.com/photos/moragcasey/] </li></ul>
    6. 6. Bringing the EPC Network to the Web? <ul><li>WS-* are adequate for business integration: </li></ul><ul><ul><li>with an ERP (Enterprise Resource Planner). </li></ul></ul><ul><ul><li>with a point of sale software. </li></ul></ul><ul><li>But not so for more light-weight, ad-hoc integration [Paut08,09] : </li></ul><ul><ul><li>Low entry barrier. </li></ul></ul><ul><ul><li>Web (browsing, bookmarking, emailing, etc.) and Web mashups (JS, etc.). </li></ul></ul><ul><ul><li>Mobile applications, resource constrained devices. </li></ul></ul><ul><li>Thus the idea to offer an alternate, RESTful interface for querying the EPC network. </li></ul>[Paut09]: Pautasso, Cesare, and Erik Wilde. “Why is the Web Loosely Coupled? A Multi-Faceted Metric for Service Design.” In Proc. of the 18th International World Wide Web Conference (WWW2009) . Madrid, Spain, 2009. [Paut08]: Pautasso, Cesare, Olaf Zimmermann, and Frank Leymann. “Restful web services vs. &quot;big&quot;' web services: making the right architectural decision.” In Proc. of the 17th international conference on World Wide Web (WWW '08) , 805―814. New York, NY, USA: ACM, 2008.
    7. 7. ARCHITECTURE <ul><li>Resource design, RESTful framework, implementation </li></ul><ul><li>[www.flickr.com/photos/julianbleecker ] </li></ul>REST? tinyurl.com/ restwife
    8. 8. Design: Addressability & Connectedness <ul><li>Resources: </li></ul><ul><ul><li>Locations, Readers, Tagged objects (EPC), etc. </li></ul></ul><ul><li>Links: </li></ul><ul><ul><li>Every resource is linked to its children. </li></ul></ul><ul><ul><li>And to relevant resources. </li></ul></ul>BASE_URL/ location /migros:basel/ reader /warehouse:incoming/ time /2009-12-21T13:22:04.000Z/ event /EPC Richardson, Leonard, and Sam Ruby. RESTful Web Services . O'Reilly Media, Inc., 2007.  
    9. 9. Design: Wait, the EPCIS is not Hierachical! <ul><li>The EPCIS data isn‘t really hierachical: </li></ul><ul><ul><li>E.g. an EPC can be seen by many readers. </li></ul></ul><ul><ul><li>Running more complex queries (e.g. all events occuring in 2010 for urn:epc:id:sgtin: 0057000.123430.2025) becomes cumbersome! </li></ul></ul><ul><ul><li>We offer a query-parameter based interface as well. </li></ul></ul><ul><ul><li>Still is RESTful! </li></ul></ul>BASE_URL/ eventquery/ result?param1=value1&..& paramN=valueN BASE_URL/ eventquery/result? reader=sap:regensdorf:frc:storage& epc=urn:epc:id:sgtin:200057000.*
    10. 10. Design: Representations <ul><li>RESTful APIs should offer several resprentations: </li></ul><ul><ul><li>XML for respecting the EPCIS standard. </li></ul></ul><ul><ul><li>HTML for browsability. </li></ul></ul><ul><ul><li>JSON for Web (e.g. Javascript) integration. </li></ul></ul><ul><ul><li>Atom feeds for subscription to queries. </li></ul></ul><ul><ul><li>The right representation for the right use case through “HTTP content negotiation” </li></ul></ul>
    11. 11. Implementation: Which REST Framework? <ul><li>Major (Java, JAX-RS) frameworks: </li></ul><ul><ul><li>Apache CFX, RestEasy, Apache Wink </li></ul></ul><ul><ul><li>Restlet: </li></ul></ul><ul><ul><ul><li>+/- One to one translation of Roy Fielding‘s thesis. [Field00] </li></ul></ul></ul><ul><ul><ul><li>+ Great community, first framework. </li></ul></ul></ul><ul><ul><ul><li>Not a great support for JAX-RS. </li></ul></ul></ul><ul><ul><li>Jersey: </li></ul></ul><ul><ul><ul><li>+/- Higher abstraction </li></ul></ul></ul><ul><ul><ul><li>+ Good community. </li></ul></ul></ul><ul><ul><ul><li>+ Ref. implementation of JAX-RS. </li></ul></ul></ul><ul><ul><ul><li>+ IDE support (Netbeans). </li></ul></ul></ul><ul><ul><ul><li>+ Integration with Grizzly (comet, etc.) </li></ul></ul></ul>[Field00]: Fielding, Roy Thomas. “ Architectural styles and the design of network-based software architectures.” University of California, Irvine, 2000.   [ googlevolume.com/jax-rs-implementations ]
    12. 12. Implementation: Component Architecture <ul><li>RESTful EPCIS as a independent component: </li></ul><ul><ul><li>+ Can be plugged on top of any EPCIS (standard) implementation. </li></ul></ul><ul><ul><li>+ Keeps the EPCIS WS-* interface safe. </li></ul></ul><ul><ul><li>- Computational overhead due to REST -> WS-* translation. </li></ul></ul>
    13. 13. Benchmarking REST vs WS-*
    14. 14. DEMONSTRATION <ul><li>A Mashup Tool for the Web of Things </li></ul><ul><li>[ www.flickr.com/photos/lpettinati ] </li></ul>
    15. 15. Demo: EPC Mashup Dashboard <ul><li>A Javascript (Google Web Toolkit) mashup for: </li></ul><ul><ul><li>Product managers to get live business intelligence for their products </li></ul></ul><ul><ul><li>Consumers to better understand: </li></ul></ul><ul><ul><ul><li>Where is my product coming from </li></ul></ul></ul><ul><ul><ul><li>What do people think about it, etc. </li></ul></ul></ul>What are my current stock levels for this Chocolate? Where is this Chocolate coming from? Where is the new one I ordered?
    16. 16. Dominique Guinard guinard.org SAP Research / ETH Zurich dominique.guinard at sap.com Mathias Mueller diuf.unifr.ch/softeng University of Fribourg, CH mathias.mueller at unifr.ch Delicious: delicious.com/misterdom/RESTfulEPCIS Blog: webofthings.com
    17. 17. Backup
    18. 18. The EPC Network in a Nutshell <ul><li>EPC (Electronic Product Code) Network: </li></ul><ul><ul><li>Creating an “Internet of Things”. </li></ul></ul><ul><ul><li>Global standard network of RFID data. </li></ul></ul><ul><ul><li>Standardization from tags (TDS), readers (LLRP), aggregators (ALE), information system (EPCIS), etc. </li></ul></ul>[ www.epcglobalinc.org/standards ]

    ×