You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by "Zedler, Michel" <Mi...@iao.fhg.de> on 2004/03/11 16:21:37 UTC

Accessing Request Data With Axis WebService

Hi all,

 

Here is my question:
Is there any possibility to access data from a soap-request-message
in my web service implementation? (Apart from the rpc parameters for the
called method.)
It seems the Axis Servlet (ServiceManager) is hiding that all from me
(?).

 

Here is my scenario:

In order to simulate many services sharing the same implementation

several mappings point to one and the same service.

This was done by deploying the same service under varying names,
so that the service can now be reached under these urls:

 

http://localhost:8080/axis/services/SERVICEMAPPING1
<http://localhost:8080/axis/services/SERVICEMAPPING1> 
http://localhost:8080/axis/services/SERVICEMAPPING2
<http://localhost:8080/axis/services/SERVICEMAPPING2> 
http://localhost:8080/axis/services/SERVICEMAPPING3
<http://localhost:8080/axis/services/SERVICEMAPPING3> 

 

Now the web service should find out at runtime which mapping
(SERVICEMAPPING[1-3])
was actually used.

 

How can I achieve this using axis?

 

Thanks a lot,
Michel

 

Re: Accessing Request Data With Axis WebService

Posted by Jeff Greif <jg...@alumni.princeton.edu>.
NachrichtThe static method
org.apache.axis.MessageContext.getCurrentContext()
returns the MessageContext of the current request.  From that you can find
out just about anything (see the Axis FAQ and user guide and javadocs for
MessageContext).

Jeff
----- Original Message ----- 
From: Zedler, Michel
To: axis-user@ws.apache.org
Sent: Thursday, March 11, 2004 7:21 AM
Subject: Accessing Request Data With Axis WebService


Hi all,

Here is my question:
Is there any possibility to access data from a soap-request-message
in my web service implementation? (Apart from the rpc parameters for the
called method.)
It seems the Axis Servlet (ServiceManager) is hiding that all from me (?).

Here is my scenario:
In order to simulate many services sharing the same implementation
several mappings point to one and the same service.

This was done by deploying the same service under varying names,
so that the service can now be reached under these urls:

http://localhost:8080/axis/services/SERVICEMAPPING1
http://localhost:8080/axis/services/SERVICEMAPPING2
http://localhost:8080/axis/services/SERVICEMAPPING3

Now the web service should find out at runtime which mapping
(SERVICEMAPPING[1-3])
was actually used.