Yes ... semantics are out-of-band.

I think that's been Steve's point. That's why I disagree with Jan's
assertion that "self-described" requires standard methods and standard
payload. From my perspective, "self-described" means that the receiving
application can determine the type of the contents based just on what's in
the message. In fact, if the message also indicates what should be done with
the contents (e.g., an embedded method indicator), the message is even more
self-described.

But I will also state that if you need to support Internet-scale
requirements, then a uniform interface, established conventions regarding
the effects and idempotency of particular methods, and the ability to cache
resource representations definitely wins.

Anne

On 09 Mar 2007 15:18:16 -0800, Mike Glendinning <[EMAIL PROTECTED]> wrote:

  Anne,

I can see the elegance of some designs using REST (e.g. APP), but I'm
a bit confused by the insistence that the only semantics on offer are
GET, PUT, POST, DELETE.

Yesterday, I visited "www.amazon.co.uk" with my browser, performed a
couple of GET operations, a POST operation and another GET.

Imagine my surprise when this morning a book was delivered to me and
I discovered that my credit card had been charged £12.45.

How did this happen? I only performed GET and POST, both well-
defined operations. Why was my credit card charged and why did I
receive a book in the post?

Later on, I pointed the browser at one of the account pages offered
by my ISP and performed exactly the same series of operations: GET,
GET, POST and GET. My sister later rang to say she had received an
email from me at around the same time. How did this happen? I
performed the same sequence of GET and POST operations and expected
to receive a book (like a monkey, I learn pretty quickly :-). Why
did this time an email get sent instead?

So it seems that in REST, if I perform the same operations, it seems
the "real world effect" might be different in every case. That
doesn't sound very uniform to me. Where do the additional semantics
come from?

Thanks,

-Mike Glendinning.

--- In 
[email protected]<service-orientated-architecture%40yahoogroups.com>,
"Anne Thomas
Manes" <[EMAIL PROTECTED]> wrote:
>
> Gregg,
>
> "invoke" is not a uniform interface because it doesn't work unless
you also
> supply a method name to invoke. And in RMI, the method names are not
> uniform. They are getXXX and setXXX for each of the public
attributes in the
> object, plus any other operations that the developer chooses to
expose.
>
> In REST, you also have the equivalent of "invoke", but the methods
that you
> can invoke are always uniform. In the case of HTTP, they are GET,
PUT, POST,
> DELETE.
>
> Anne
>

Reply via email to