Rest and the hypermedia constraint

Technical Assurance Manager at Inviqa
Oct. 8, 2011
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
Rest and the hypermedia constraint
1 of 66

More Related Content

What's hot

Kong API Gateway Kong API Gateway
Kong API Gateway Chris Mague
Introduction to the Web APIIntroduction to the Web API
Introduction to the Web APIBrad Genereaux
RESTful API - Best PracticesRESTful API - Best Practices
RESTful API - Best PracticesTricode (part of Dept)
REST APIREST API
REST APITofazzal Ahmed
Design Beautiful REST + JSON APIsDesign Beautiful REST + JSON APIs
Design Beautiful REST + JSON APIsStormpath
REST-API introduction for developersREST-API introduction for developers
REST-API introduction for developersPatrick Savalle

Viewers also liked

The Internet as Web Services: introduction to ReSTThe Internet as Web Services: introduction to ReST
The Internet as Web Services: introduction to ReSTBruno Kessler Foundation
RESTful servicesRESTful services
RESTful servicesgouthamrv
Introduction To RESTIntroduction To REST
Introduction To RESTBhavya Siddappa
Learn REST in 18 SlidesLearn REST in 18 Slides
Learn REST in 18 SlidesSuraj Gupta
HATEOAS 101 - Opinionated Introduction to a REST API StyleHATEOAS 101 - Opinionated Introduction to a REST API Style
HATEOAS 101 - Opinionated Introduction to a REST API StyleApigee | Google Cloud
REST PresentationREST Presentation
REST PresentationAlexandros Marinos

Similar to Rest and the hypermedia constraint

REST and the Hypermedia ConstraintREST and the Hypermedia Constraint
REST and the Hypermedia ConstraintInviqa
internet principles of operation By ZAKinternet principles of operation By ZAK
internet principles of operation By ZAKTabsheer Hasan
HTTP: the Other ESBHTTP: the Other ESB
HTTP: the Other ESBRyan Riley
HTTP1.1/2 overviewHTTP1.1/2 overview
HTTP1.1/2 overviewAndrew Muntian
RESTful APIsRESTful APIs
RESTful APIsAdi Challa
WebWeb
WebMayank Vora

Recently uploaded

The Flutter Job Market At The MomentThe Flutter Job Market At The Moment
The Flutter Job Market At The MomentAhmed Abu Eldahab
Machine learning with quantum computersMachine learning with quantum computers
Machine learning with quantum computersSpeck&Tech
Easy Salesforce CI/CD with Open Source Only - Dreamforce 23Easy Salesforce CI/CD with Open Source Only - Dreamforce 23
Easy Salesforce CI/CD with Open Source Only - Dreamforce 23NicolasVuillamy1
Unleashing Innovation: IoT Project with MicroPythonUnleashing Innovation: IoT Project with MicroPython
Unleashing Innovation: IoT Project with MicroPythonVubon Roy
Supplier Sourcing_Cathy.pptxSupplier Sourcing_Cathy.pptx
Supplier Sourcing_Cathy.pptxCatarinaTorrenuevaMa
Improving Employee Experiences on Cisco RoomOS Devices, Webex, and Microsoft ...Improving Employee Experiences on Cisco RoomOS Devices, Webex, and Microsoft ...
Improving Employee Experiences on Cisco RoomOS Devices, Webex, and Microsoft ...ThousandEyes

Rest and the hypermedia constraint

Editor's Notes

  1. \n
  2. \n
  3. Developer for 20 years\nProfessional developer since 2002\nStarted on C, C++ and Perl\nFocussed on Perl and moved into web app development where I picked up PHP\nmobile web, standards and software architectures\n
  4. Technical Team Lead since the start of 2010\nOne of the Sheffield office founders\n
  5. Sole developer of fdrop.it\nCreated to solve my problem of ‘why is it so difficult to send a file to someone online?’\n
  6. \n
  7. \n
  8. Doctoral Dissertation\n‘Architectural Styles and the Design of Network-based Software Architectures’\n\none of the principle author of HTTP specification (RFC 1945/2616)\nIn 1999 he was named my MIT Technology Review as one of the top 100 innovators in the world under 35\n\n\n
  9. \n
  10. Constraints help to guide the creative project\n\nSacrifice is usually made retroactively\n
  11. Can be applied to ANY distributed system\nWeb application or API design\n
  12. \n
  13. Clients not concerned about data storage\nServers not concerned about the user interface or user state\ncomponents evolve independently if interface remains constant\n
  14. Each request from the client must contain ALL of the information required\nCannot rely on stored context on the server\nSession state on the client\nVisibility (Server can be observed at any time), Reliability (network failure), Scalability (easy to add servers)\n
  15. Responses must implicitly or explicitly define themselves as cacheable or not\nFurther improves scalability and performance\n\n
  16. Client connected to the end server or to an intermediary along the way.\nLoad Balancers\nSecurity Policies at a Firewall\nReverse Proxy Cache\n\n
  17. Service can temporarily extend client side functionality by providing code it can execute \nie, Javascript or java applets\n\nTHE OPTIONAL CONSTRAINT!\n
  18. Four guiding principles to simplify architecture\n
  19. On the web we use URI’s\n\nResources themselves are usually different to what is returned to the client\nUsually, a database resource will be represented in JSON or XML\n
  20. When a client holds a representation, it is enough to be able to modify or delete the resource assuming the user has permission to do so\n
  21. Each message describes itself. This means using an explicit mime type, and explicitly if the resource can be cached.\n
  22. Clients make state transitions ONLY through links returned within the resource (ie, anchors in html)\n\nOnly exception is the entry point\n
  23. HATEOAS is a horrible acronym\n
  24. Using hypermedia (anchor, xlink, etc)\n
  25. and it’s why it’s been so successful over the last 20 years. The web is 20 years old. That’s amazing - and because of standards and hypermedia, I can still reference things from 20 years ago.\n
  26. A web page contains all the information within it to allow the user to move from the current state, to the next.\n
  27. All types of HTML\nXHTML\n\nVersions within them are identified by the content (DOCTYPE, html tag or xml header)\nXML documents not processed as XML (no checks for well formedness)\n \n
  28. HTML 5 won over XHTML for who gains supremacy over the browsers - HTML contains some really good stuff about describing text, images, user input etc and what HTTP function to use on them (ie, GET image, POST a form).\n
  29. This is how you declare an html 5 document. It’s great for the web as browsers only need to understand GET and POST - this is fine and it’s still RESTful, but what if we need a representation of a resource that can support other actions?\n
  30. \n
  31. HTML is a hypermedia type\nXML is not\n
  32. Accept header in HTTP\n
  33. HTTP headers and Hypermedia!\n
  34. \nHTTP 1.1 defines these 9 methods. HTML lets us use 2 of them. \n
  35. That’s all you get in a browser\n\n
  36. \n
  37. GET to retrive, POST to create, PUT to update, DELETE\nPOST to a job queue to update and delete\nThese are HTTP, not REST (REST just defines the uniform interface)\n
  38. API for free?\nDownsides\nSome actions need to be different over an API due to different UI\nAJAX\n
  39. Focus on the UI breaks the API\n
  40. Craft my own XML doc\nNeed to define my media type first\nToo much like work...\n
  41. There was merit to this - which i’ll come back to\n
  42. Remove the markup from the XHTML that was only there to layout the UI\nServe HTML5 to browsers on text/html!\nClose - but webkit on iOS and Android devices prefer XML\n
  43. \n
  44. \n
  45. XHTML still in the media type so still self describing\nWont conflict with browsers\n\n
  46. \n\n
  47. form, input, img, a\nBrowsers already understand XHTML\nEasy for people to consume using any XML Reader\nDEMO\n
  48. XHTML only supports GET and POST\nWhat if we need more?\n
  49. \n
  50. \n
  51. \n
  52. \n
  53. \n
  54. \n
  55. \n
  56. \n
  57. \n
  58. \n
  59. \n