W3C home > Mailing lists > Public > www-ws-desc@w3.org > June 2004

Re: Which operation?

From: David Booth <dbooth@w3.org>
Date: Mon, 14 Jun 2004 17:56:40 -0400
Message-Id: <5.1.0.14.2.20040614145931.0328be78@localhost>
To: Mark Baker <distobj@acm.org>, www-ws-desc@w3.org
Cc: "David Orchard" <dorchard@bea.com>, Mark Nottingham <mnot@mnot.net>

Mark Baker,

Since we're trying to finish up items on our issues list, and issue #168[1] 
is one of the remaining issues, I thought I'd offer my thoughts on the 
question that you raised.

If I understand correctly, you asked what operation the provider agent 
invoked, when it responded to a message from a requester agent (per the 
following WSDL document).

>     <wsdl:interface name="StockQuotes">
>         <wsdl:operation name="getStockQuote">
>             <wsdl:input element="schema1"/>
>             <wsdl:output element="schema2"/>
>         </wsdl:operation>
>     </wsdl:interface>

My answer would be: That depends on the semantics of the application, and 
the implementation of the provider agent, which are outside the scope of 
the WSDL 2.0 language.

The WSDL document that you show below asserts that if the provider agent 
receives an acceptable message conforming to schema1, then it will send 
back a message conforming to schema2.  It says nothing about the semantics 
of the interaction, or what the provider agent will do in response to 
receiving the message (other than sending back a reply message conforming 
to schema2).

The schema of the input message (schema1 in your example) defines the 
minimum information that the provider agent will obtain upon receiving a 
request message from the requester agent.  If the provider agent somehow 
receives additional information, such as the HTTP method used (GET) or even 
the name of the wsdl:operation (getStockQuote), then it is free to make use 
of that additional information in deciding what to do.  But again, that is 
up to the application semantics of the service.  The WSDL 2.0 specification 
has nothing to say about what information the provider agent should or 
should not consider in deciding what to do.

A different (but related) question is raised by David Orchard's example[2]:

>      <wsdl:interface name="StockQuotes">
>          <wsdl:operation name="getStockQuote" wsdl:webMethod="GET">
>              <wsdl:input element="schema1"/>
>              <wsdl:output element="schema2"/>
>          </wsdl:operation>
>          <wsdl:operation name="getStockQuoteGoldPayingCustomer" 
> wsdl:webMethod="GET">
>              <wsdl:input element="schema1"/>
>              <wsdl:output element="schema2"/>
>          </wsdl:operation>
>      </wsdl:interface>

If the provider agent receives a message conforming to schema1, how can it 
know whether the requester agent was intending to perform wsdl:operation 
getStockQuote or wsdl:operation getStockQuoteGoldPayingCustomer, since they 
both use the same input schema (schema1)?  The short answer is: That is the 
application's problem -- not the WSDL 2.0 specification's problem.

The bottom line is that the provider agent receives whatever information it 
receives.  What it chooses to *do* with that information (aside from 
sending back a message conforming to schema2) is entirely beyond the scope 
of the WSDL 2.0 specification.  And if the provider agent doesn't receive 
enough information to know what the requester agent wanted, then it is out 
of luck: whoever designed the service should have designed it differently.

In short, the WSDL documents above say nothing about what actual operation 
the provider agent will perform.  You need to know the application 
semantics to determine that.

Does this address your concern?

References
1. Issue 168: 
http://dev.w3.org/cvsweb/%7Echeckout%7E/2002/ws/desc/issues/wsd-issues.html#x168
2. DaveO's example: 
http://lists.w3.org/Archives/Public/www-ws-desc/2004Apr/0045.html


At 11:57 AM 4/19/2004 -0400, Mark Baker wrote:

>Hi,
>
>I've finally got a bit of time on my hands (arguably the only upside of
>stomach flu), and wanted to follow up with Hugo, Dave, etc.. on the
>desribing-RESTful-services thread.  But I found myself needing some
>clarification first.
>
>If, using the following WSDL, we had a WSDL operation bound to HTTP GET,
>and we sent a message containing a document conformant with schema1, and
>received a successful response including the contents of schema2, what
>was the operation that was invoked?  "GET" or "getStockQuote"?
>
>     <wsdl:interface name="StockQuotes">
>         <wsdl:operation name="getStockQuote">
>             <wsdl:input element="schema1"/>
>             <wsdl:output element="schema2"/>
>         </wsdl:operation>
>     </wsdl:interface>
>
>I've been told that wsdl:operation is just documentation, which is
>exactly how I see it too (which would suggest that "GET" was the
>operation that was invoked).  But so much of what WSDL is used for today
>doesn't use it that way, and from what I can tell, there's no way to
>tell which interpretation a given WSDL document is using.  FWIW, this
>also relates to Umit's operationName work as well as my previous issue
>about "ambiguous interface semantics".
>
>Thanks.
>
>Mark.
>--
>Mark Baker.   Ottawa, Ontario, CANADA.        http://www.markbaker.ca

-- 
David Booth
W3C Fellow / Hewlett-Packard
Telephone: +1.617.253.1273
Received on Monday, 14 June 2004 17:56:47 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 7 December 2009 10:58:31 GMT