app primer

images/atom.png

Ed Summers <ehs@pobox.com>

Who?



images/duran.jpg

What?


Main Entry: 1primer
Pronunciation: 'pri-m&r, chiefly British 'prI-m&r
Function: noun
Etymology: Middle English, layperson's prayer book, from Anglo-French, from Medieval Latin primarium, from Late Latin, neuter of primarius primary
1 : a small book for teaching children to read
2 : a small introductory book on a subject
3 : a short informative piece of writing

RFC 4287

<feed xmlns="http://www.w3.org/2005/Atom"> <id>http://planet.code4lib.org</id> <title>planet code4lib</title> <updated>2007-02-25T02:02:04+00:00</updated> <entry> <title>code4lib: Code4Lib 2008 will be in Portland, OR</title> <link rel="alternate" type="text/html" href="http://www.code4lib.org/node/166"/> <id>http://planet.code4lib.org/166</id> <updated>2007-02-25T01:06:59+00:00</updated> <author><name>Roy Tennant</name></author> <content type="html"> Voting on the location of Code4Lib 2008 is now closed and the offer from Oregon State University to host in Portland, OR is the winner... </content> </entry> </feed>

Representational State Transfer


Atom Publishing Protocol






Atom + REST = APP

A Few Particulars

Service Document

<?xml version="1.0" encoding='utf-8'?> <service xmlns="http://purl.org/atom/app#" xmlns:atom="http://www.w3.org/2005/Atom"> <workspace> <atom:title>One Big Library</atom:title> <collection href="http://onebiglibrary.net/story/" > <atom:title>Stories</atom:title> </collection> <collection href="http://onebiglibrary.net/pics/"> <atom:title>Pictures</atom:title> <accept>image/*</accept> </collection> </workspace> <workspace> ... </workspace> </service>

Create






       Client                                     Server
         |                                           |
         |  1.) POST to URI of Collection            |
         |------------------------------------------>|
         |                                           |
         |  2.) 201 Created                          |
         |      Location: Member Entry URI           |
         |<------------------------------------------|
         |                                           |

Read






       Client                                     Server
         |                                           |
         |  1.) GET to Member URI                    |
         |------------------------------------------>|
         |                                           |
         |  2.) Member Representation                |
         |<------------------------------------------|
         |                                           |

Update






       Client                                     Server
         |                                           |
         |  1.) PUT to Member URI                    |
         |------------------------------------------>|
         |                                           |
         |  2.) 200 OK                               |
         |<------------------------------------------|
         |                                           |

Delete






       Client                                     Server
         |                                           |
         |  1.) DELETE to Member URI                 |
         |------------------------------------------>|
         |                                           |
         |  2.) 200 Ok                               |
         |<------------------------------------------|
         |                                           |

Google Data

The Ultimate Web Programming Language





images/curl.jpg

invoke(thom)


images/thom.jpg

Advantages

Loose Ends