applications Enables services to evolve independently Need not be tied to specific implementation Easier to scale portions of the system Compose applications out of existing services
implementations of WS-* in Python, Perl, Ruby, and PHP. You won’t see them, because there’s no intrinsic value in WS-*, unless you’re trying to suck money out of your customers. Its complexity serves as a barrier to entry at the same time that it creates 'value' that can be sold.” Mark Nottingham, one time chair of WS-Addressing working group
Services space today, not only because it is complex and unwieldy, but also because it supports an inherently unsuitable model for Internet-scale systems. WSDL-based toolkits make choosing inappropriate engineering decisions easy, which substantially increases technical risk when using the WS-* stack.” -Rest in Practice
protocol Principal HTTP verbs describe important changes to application state GET, PUT, POST, & DELETE (a bit like CRUD in databases) ...and if you can’t, think about if the application should be on the web.
nouns ~ objects; verbs ~ messages URIs name application states; You manipulate representations Similar to OO-design where the verbs have been already picked out for you.
COPY HEAD OPTIONS 200 OK 201 Created 202 Accepted 304 Not modified 400 Bad request 404 Not found 409 Conflict 500 Internal Server Error safe unsafe idempotent idempotent safe safe http verbs http status codes
resource is uniquely identified; A resource may have several representations (e.g. html, json, xml) Manipulate resources through their representations Use the standard HTTP verbs to manipulate the resources Hypermedia as the engine of application state * Resources can include links that let consumers discover possible state transitions Self-descriptive messages Separation of control from the data allows for layered architecture; the non-functional requirements can be deferred to the intermediaries. *Clients should have prior knowledge of the service media-types
• WS-* (tunneling over HTTP post) - not safe, not idempotent, and therefore never cacheable • Support conditional GETs (If-modified-since, E-Tags) Client Load Balancer Cache Cache-control: public, max-age = 600
(REST) Management /Auditing Web Services for Distributed Data Management (WS-*) vs. intermediary logs (REST) Reliability WS-ReliableMessaging (WS-*) vs. reliable business process (REST) Transactions WS-Transactions (WS-*) vs. no place in distributed, unreliable environments (REST)
brittle HTTP/1.1 is a good application protocol REST offers a proven, viable model for architecting distributed systems. REST requires a paradigm shift from RPC APIs to generate/consume REST are widely available
proportional to the simplicity of the result.” Roy Fielding Author of seminal dissertation on REST “Architectural Styles and the Design of Network-based Software Architectures”
- Shalva Usobov https://speakerdeck.com/shaliko/service-oriented-architecture How to GET a Cup of Coffee - Webber, Parastatidis, Robinson http://www.infoq.com/articles/webber-rest-workflow Rest Assured - Hypermedia APIs with Spring - Oliver Gierke https://speakerdeck.com/olivergierke/hypermedia-apis-with-spring-2 Rest as better web service paradigm - Norman Gray http://wiki.ivoa.net/internal/IVOA/InterOpMay2007GridAndWebServices/talk-gray-rest.pdf Take a REST! - Cyril Rohr https://speakerdeck.com/crohr/take-a-rest