How to obtain SOAP request XML in @WebMethod methods of a JAX-WS web service

Solution Unverified - Updated -

Issue

  • I coded a simple web service using JAX-WS.
  • I need to have access to the SOAP request XML so that I can send the entire XML string back as CDATA in the response.
  • I tried doing that using injection with the @Resource WebServiceContext but I am not able to access the request XML string.
  • I used @HandlerChain and wrote a handler class that implements the SOAPHandler but I do not have a way of associating/connecting the xml in the handler class with the parameters that get passed into the web method itself.
  • What would be the best way to obtain the SOAP request XML?

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 5.x
    • 6.x

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content