On Tue, 2004-11-09 at 15:33, Jan Algermissen wrote:
> So, we should develop a counter example to give people a chance to
> compare. I think REST WS desparately need live examples. That's how
> people learn.
Yeah ... you're right.
Attached is a simple python script [depending on twisted] implementing
most of a /queue web service. Specifically:
GET / [overall docs]
GET /queue
POST /queue => /queue/{name}
GET /queue/{name}
DELETE /queue/{name}
POST /queue/{name} => /queue/{name}/{key} = {item}
GET /queue/{name}/{key}
DELETE /queue/{name}/{key}
...are supported. The response is mostly HTML, with html:form's for the
POSTS and an escaped version of a "queue" XML format ... if I spent more
than a couple of hours on it I'd probably go with RDF.
./queue.py to run [assuming python + twisted]; binds to port 8000.
Notably absent are:
* auth [HTTP or otherwise]
* queue configuration
* the weird timeout/locking thing...
* persistance, stability, &c...
> I'll start doing that this week. If anybody's interested to join in I;d be
> happy. Let me know.
Sorry ... this has [obviously] been bothering me today. :)
...jsled
--
http://asynchronous.org/ - `a=jsled; b=asynchronous.org; echo ${a}@${b}`