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 "Marvin D. Toll" <Ma...@gtcGroup.com> on 2009/04/20 17:04:07 UTC

The org.apache.axis2.jaxws.message.databinding.impl.JAXBBlockImpl block object is already consumed.

Environment:  WebSphere Platform 6.1 [BASE 6.1.0.21 cf210844.13] [WEBSERVICES
6.1.0.21 cf210844.03]
Topic: Retrieving the SOAP Message.

The SOAPMessageContext can be retrieved in one of two ways:

	Handler
                          public boolean handleMessage(SOAPMessageContext
soapMessageContext)
	EndPoint
		@Resource
                          private WebServiceContext webServiceContext;
                          // webServiceContext.getMessageContext();

If there is no inbound payload the SOAPMessage may be retrieved as follows
using either strategy:

	SOAPMessage soapMessage = soapMessageContext.getMessage();

However, if there is an inbound payload the @Resource strategy yields the
following when retrieving the SOAP message:

Caused by: javax.xml.ws.WebServiceException: An internal error occurred. The
org.apache.axis2.jaxws.message.databinding.impl.JAXBBlockImpl block object
is already consumed. Processing cannot continue.  Run with the debug option
to determine where the block was first consumed.
	at
org.apache.axis2.jaxws.ExceptionFactory.createWebServiceException(ExceptionFactory.java:178)
	at
org.apache.axis2.jaxws.ExceptionFactory.makeWebServiceException(ExceptionFactory.java:79)
	at
org.apache.axis2.jaxws.ExceptionFactory.makeWebServiceException(ExceptionFactory.java:125)
	at
org.apache.axis2.jaxws.message.impl.BlockImpl.outputTo(BlockImpl.java:376)
	at
org.apache.axis2.jaxws.message.impl.BlockImpl.serialize(BlockImpl.java:309)
	at
org.apache.axiom.om.impl.llom.OMSourcedElementImpl.internalSerialize(OMSourcedElementImpl.java:570)
	at
org.apache.axiom.om.impl.llom.OMElementImpl.internalSerialize(OMElementImpl.java:789)
	at
org.apache.axiom.om.impl.llom.OMElementImpl.internalSerialize(OMElementImpl.java:773)
	at
org.apache.axiom.soap.impl.llom.SOAPEnvelopeImpl.internalSerialize(SOAPEnvelopeImpl.java:247)
	at
org.apache.axiom.om.impl.llom.OMElementImpl.internalSerialize(OMElementImpl.java:773)
	at org.apache.axiom.om.impl.llom.OMNodeImpl.serialize(OMNodeImpl.java:345)
	at org.apache.axiom.om.impl.llom.OMNodeImpl.serialize(OMNodeImpl.java:389)
	at
org.apache.axis2.jaxws.message.impl.MessageImpl.getAsSOAPMessage(MessageImpl.java:192)
	at
org.apache.axis2.jaxws.handler.SoapMessageContext.getMessage(SoapMessageContext.java:111)
	at
com.ford.it.wscore.context.WscBaseProviderOrchestrator.getSoapMessage(WscBaseProviderOrchestrator.java:564)
	at
com.ford.it.wscore.context.WscBaseProviderOrchestrator.getSoapPart(WscBaseProviderOrchestrator.java:581)
	at
com.ford.it.wscore.context.WscBaseProviderOrchestrator.parseXmlFromSoapPart(WscBaseProviderOrchestrator.java:748)
	at
com.ford.it.wscore.context.WscBaseProviderOrchestrator.logRequest(WscBaseProviderOrchestrator.java:226)
	... 37 more


Note: Only non-API Google hits on this exception are in reference to an
Axis2 unmarshaling bug resolved 4/2007.

Any ideas why we see different behavior depending on which strategy used to
retrieve the SOAP Message?

Thanks,
Marvin

-- 
View this message in context: http://www.nabble.com/The-org.apache.axis2.jaxws.message.databinding.impl.JAXBBlockImpl-block-object-is-already-consumed.-tp23138529p23138529.html
Sent from the Axis - User mailing list archive at Nabble.com.


Re: The org.apache.axis2.jaxws.message.databinding.impl.JAXBBlockImpl block object is already consumed.

Posted by Davanum Srinivas <da...@gmail.com>.
Marvin,

This seems to be a problem with the Web services feature pack. Better place to ask this question is:
http://www.ibm.com/developerworks/forums/forum.jspa?forumID=266&start=0

You may also want to raise a PMR with IBM support in parallel. Definitely something is wrong and you may have to get 
them traces to look through.

thanks,
dims

On 04/20/2009 11:04 AM, Marvin D. Toll wrote:
> Environment:  WebSphere Platform 6.1 [BASE 6.1.0.21 cf210844.13] [WEBSERVICES
> 6.1.0.21 cf210844.03]
> Topic: Retrieving the SOAP Message.
>
> The SOAPMessageContext can be retrieved in one of two ways:
>
> 	Handler
>                            public boolean handleMessage(SOAPMessageContext
> soapMessageContext)
> 	EndPoint
> 		@Resource
>                            private WebServiceContext webServiceContext;
>                            // webServiceContext.getMessageContext();
>
> If there is no inbound payload the SOAPMessage may be retrieved as follows
> using either strategy:
>
> 	SOAPMessage soapMessage = soapMessageContext.getMessage();
>
> However, if there is an inbound payload the @Resource strategy yields the
> following when retrieving the SOAP message:
>
> Caused by: javax.xml.ws.WebServiceException: An internal error occurred. The
> org.apache.axis2.jaxws.message.databinding.impl.JAXBBlockImpl block object
> is already consumed. Processing cannot continue.  Run with the debug option
> to determine where the block was first consumed.
> 	at
> org.apache.axis2.jaxws.ExceptionFactory.createWebServiceException(ExceptionFactory.java:178)
> 	at
> org.apache.axis2.jaxws.ExceptionFactory.makeWebServiceException(ExceptionFactory.java:79)
> 	at
> org.apache.axis2.jaxws.ExceptionFactory.makeWebServiceException(ExceptionFactory.java:125)
> 	at
> org.apache.axis2.jaxws.message.impl.BlockImpl.outputTo(BlockImpl.java:376)
> 	at
> org.apache.axis2.jaxws.message.impl.BlockImpl.serialize(BlockImpl.java:309)
> 	at
> org.apache.axiom.om.impl.llom.OMSourcedElementImpl.internalSerialize(OMSourcedElementImpl.java:570)
> 	at
> org.apache.axiom.om.impl.llom.OMElementImpl.internalSerialize(OMElementImpl.java:789)
> 	at
> org.apache.axiom.om.impl.llom.OMElementImpl.internalSerialize(OMElementImpl.java:773)
> 	at
> org.apache.axiom.soap.impl.llom.SOAPEnvelopeImpl.internalSerialize(SOAPEnvelopeImpl.java:247)
> 	at
> org.apache.axiom.om.impl.llom.OMElementImpl.internalSerialize(OMElementImpl.java:773)
> 	at org.apache.axiom.om.impl.llom.OMNodeImpl.serialize(OMNodeImpl.java:345)
> 	at org.apache.axiom.om.impl.llom.OMNodeImpl.serialize(OMNodeImpl.java:389)
> 	at
> org.apache.axis2.jaxws.message.impl.MessageImpl.getAsSOAPMessage(MessageImpl.java:192)
> 	at
> org.apache.axis2.jaxws.handler.SoapMessageContext.getMessage(SoapMessageContext.java:111)
> 	at
> com.ford.it.wscore.context.WscBaseProviderOrchestrator.getSoapMessage(WscBaseProviderOrchestrator.java:564)
> 	at
> com.ford.it.wscore.context.WscBaseProviderOrchestrator.getSoapPart(WscBaseProviderOrchestrator.java:581)
> 	at
> com.ford.it.wscore.context.WscBaseProviderOrchestrator.parseXmlFromSoapPart(WscBaseProviderOrchestrator.java:748)
> 	at
> com.ford.it.wscore.context.WscBaseProviderOrchestrator.logRequest(WscBaseProviderOrchestrator.java:226)
> 	... 37 more
>
>
> Note: Only non-API Google hits on this exception are in reference to an
> Axis2 unmarshaling bug resolved 4/2007.
>
> Any ideas why we see different behavior depending on which strategy used to
> retrieve the SOAP Message?
>
> Thanks,
> Marvin
>