REST Questions

Paul Prescod paulp@ActiveState.com
Fri, 24 Aug 2001 11:56:02 -0700


I'd like to scratch some REST Zen[1] from the minds of the gurus. I'm
naturally attracted to REST because it seems to me to be naturally
address-centric in a way that SOAP et. al. are not. I was convinced of
the goodness of address-centricity[2] back in my HyTime days and Mike
Dierkin reinforced that in a Web context when I worked with him at
DataChannel.

What would REST advocates do about non-HTTP transports? One answer might
be to tunnel HTTP. Another might be to try to use the semantics of
(e.g.) SMTP "deeply" as REST advocates suggest the use of HTTP deeply.

If you have a concept that cannot be handled directly by HTTP like
"launchSelfDestructSequence" is it REST-ish to a) define an HTTP
extension header, b) put the "method" in the body (e.g. XML-RPC
methodName) c) define a new protocol from scratch.

It is almost a no-brainer (now that I think about it!) that getStateName
and even getStockPrice should not use RPC. But eventually you may need
to do a state transition. You can certainly do that over POST but if
you're still using XML method names then it seems you haven't really
abandoned RPC (and maybe that's a good thing...maybe the two models work
well together).
-- 
Take a recipe. Leave a recipe.  
Python Cookbook!  http://www.ActiveState.com/pythoncookbook