Re: A REST challenge

Hi Edwin, sorry for the delay.

On Tue, Jul 16, 2002 at 11:41:09AM -0700, Edwin Khodabakchian wrote:
> Mark,
> 
> Conceptually speaking, in this example, what is the "resource" whose URI
> is being sent from C to S and whose state is changed each time S calls
> back C?

If I were C, I would create a unique resource for this transaction, in
case I were to trigger a subsequent transaction (say, purchasing another
pair of shoes before the new pair arrives).  It might be that the order
itself contains a unique identifier for the transaction, so creating a
new resource may not be necessary.  But the overhead in doing so is
extremely low, so that's probably best practice, and could easily be
incorporated into software as default behaviour.

So in that case, the resource could be said to represent my view of the
particular transaction.  If some error occurred, S could invoke GET on
it to find out what state I was in - or vice versa, assuming that S has
a URI that identifies its view of the same transaction.

MB
-- 
Mark Baker, CTO, Idokorro Mobile (formerly Planetfred)
Ottawa, Ontario, CANADA.               distobj@acm.org
http://www.markbaker.ca        http://www.idokorro.com

Received on Wednesday, 17 July 2002 15:46:26 UTC