Apr 20 2010

Episode 65: REST


What is with this REST stuff you keep hearing about?! We’ll give you the skinny.

News and Follow-ups – 00:33

Geek Tool – 01:50

Webapps – 06:17

Topic – 14:43

  • REST
  • What is REST?
    • A Software Architecture created by Roy Fielding in 2000 Who happens to be one of the principal authors of HTTP 1.0 and HTTP 1.1
    • What does it stand for?
      • Representational State Transfer
  • Sites using REST
    • Twitter
    • Amazon
    • Ebay
    • Facebook
    • Yahoo, Flickr
    • Youtube
    • REST is an architectural guideline, SOAP is a protocol
    • Biggest downside is that SOAP disregards many of HTTP’s existing capabilities such as authentication, caching, content type negotiation, etc.
    • Everything in SOAP is handled in a HTTP POST.
  • REST Verbs
    • GET – Give me information in specified format
      • Usually XML, JSON, or YAML; but can be any valid MIME type.
    • PUT – Replace your information with mine
    • POST – Add new information
    • DELETE – Eliminate information
  • Statelessness
    • Shouldn’t matter if the second request goes to a different server than the first
    • Authentication is provided with each request
    • The same url should return the same data regardless of cookies or session data
    • Ability to replace one server with another
    • Load balancing
  • Frameworks that support REST