dev@jax-ws.java.net

Re: return null on server side for request-response

From: Rama Pulavarthi <Rama.Pulavarthi_at_Sun.COM>
Date: Tue, 16 Jun 2009 22:21:25 -0700

Yes, Using Provider gives you flexibility to work on the messages
directly and get the behavior you want.
As far as the SEI based Endpoint is concerned is concerned, a WebMethod
marked for Request/Response MEP should either return some value or throw
an Exception just like any Java method.

thanks,
Rama Pulavarthi

Stephan Poehlsen wrote:
> Hello,
>
> the upcoming OASIS standard "Device Profile for Web Services 1.1"
> requires, that each HTTP service must support receiving a Probe SOAP
> ENVELOPE as an HTTP Request. This request has the request-response
> message exchange pattern.
>
> In case the service does not match the probe request it must response
> with a HTTP response, status code 202 Accepted and no SOAP envelope
> according to the interoperability scenario.
>
> When taking a look in the EndpointMethodHandler.invole() method
>
> Object ret = owner.getInvoker(req).invoke(req, method, args);
> responseMessage = isOneWay ? null : createResponseMessage(args, ret);
>
> it seems to me, that it is not possible to have the response message
> set to null in case where the message exchange pattern is not oneway.
>
> Is it right, that the SEI interface is not usable in this case and the
> "Provider<Source> and MESSAGE" interface must be used according to
> https://jax-ws.dev.java.net/2.2-ea/docs/provider.html
>
> To summarize: It seems to be impossible to abort a request-response
> message exchange pattern with a HTTP status code 202 Accepted when
> using the SEI interface.
>
> Is it right?
>
> Kind regards,
> Stephan
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_jax-ws.dev.java.net
> For additional commands, e-mail: dev-help_at_jax-ws.dev.java.net
>