users@jax-rpc.java.net

Passing additional information to a service endpoint class

From: Pratibha Gupta <pratibhag_at_NETSCAPE.COM>
Date: Tue, 09 Apr 2002 16:22:57 -0700

Is there a way to pass additional information to a service endpoint
class without passing it as an input parameter?

For eg. I have a business method void foo(String someString)
But foo() needs something else as well other than someString to do its
processing. This extra information is not available when the method is
called (it could be something that's encrypted in the SOAP message and
one of the handlers will decrypt the message and get that information).
How do I pass this information to the service? i.e. is there any way to
tell the jax-rpc runtime that foo() really needs to be called with 2
parameters even though the wsdl describes it to be requiring a single
parameter?

I know that the handler could put it in MessageContext, or
ServletEndPointContext (if my service was implemented as a servlet). But
I'm not too comfortable with that model, with all the discussion going
on about when ServletEndPointContext.init() is called, and how does it
ensure that the right MessageContext is passed in concurrent request
scenarios etc. I'm looking for some other way to do this.

Thanks,
Pratibha