HTTP headers in Web service [message #199350] |
Tue, 04 September 2007 11:54 |
Eclipse User |
|
|
|
Originally posted by: jon.gavia.dk
Hi
I have just made a "hello world" web service from a single HelloWorld
class containing one method which returns "hello world". This is done in
eclipse as proposed in the "Creating Bottom Up Web Service" manual.
Everything works as supposed :-)
Question:
Is it possible to get some information about the request _inside_ my
HelloWorld object ? For example something like
getJAXRPCRuntimeEnvironment.getHTTPHeaders() ????
Or what can i do ? Any suggestions are welcome
Thx
Jon Friis
|
|
|
Re: HTTP headers in Web service [message #199448 is a reply to message #199350] |
Wed, 05 September 2007 07:17 |
Eclipse User |
|
|
|
Originally posted by: jon.gavia.dk
I found the answer and therefore sharing it with the newsgroup (in case
some have a similar problem).
The line:
MessageContext msgContext =
org.apache.axis.AxisEngine.getCurrentMessageContext();
pretty much solves the whole problem, since the MessageContext handle is a
handle to the current Axis Runtime Environment. From here on you can just
start digging into the context and getting pretty much any information you
want, including HTTP headers, SOAP header, etc.
Jon Friis
|
|
|
Powered by
FUDForum. Page generated in 0.03040 seconds