It didn't work.
This is what I did: I deleted from the directory of Axis2\lib 4 files:
axiom-jaxb-1.2.19.jar, axiom-api-1.2.19.jar, axiom-dom-1.2.19.jar,
axiom-impl-1.2.19.jar
and I added these 4 files:
axiom-api-1.2.20.jar,axiom-dom-1.2.20.jar,axiom-impl-1.2.20.jar,axiom-jaxb-1.2.20.jar.
I use Axis embeded so I also deleted from my netbeans libraries the old
jars and added the new ones.
I recompiled and the error remained.
------ Original Message ------
From: "Martin Gainty" <mgai...@hotmail.com>
To: "java-user@axis.apache.org" <java-user@axis.apache.org>; "Sterpu
Victor" <vic...@caido.ro>
Sent: 2/11/2016 4:58:09 PM
Subject: Re: Raw SOAP XML response
possible outdated version of axiom
* In Axiom versions prior to 1.2.9, the sequence of events was
inconsistent if the
* underlying stream is XOP encoded and caching is disabled (see
WSCOMMONS-485).
* This made it necessary for the caller to (partially) handle the
XOP processing and to use
* {@link OMAttachmentAccessor#getDataHandler(String)} to retrieve
the binary content.
* Starting with 1.2.9 this is no longer be the case: as specified
above,
* the sequence of events is *independent of the state of the
object model*
* and the value of the <code>cache</code> parameter,
* and ALL binary content is reported through the
* {@link org.apache.axiom.ext.stax.datahandler.DataHandlerReader}
(embedded in axiom-api) extension.
upgrade axiom to 1.2.9 a recompile, package, deploy and run with 1.2.9
should mitigate the error you are now receiving
*please keep us apprised*
Martin
______________________________________________
--------------------------------------------------------------------------------
From: Sterpu Victor <vic...@caido.ro>
Sent: Wednesday, November 2, 2016 9:37 AM
To:java-user@axis.apache.org
Subject: Raw SOAP XML response
Hello
I need to save the raw SOAP XML response from Axis2(I use axis 2
1.7.3).
When Axis2 call retusrns an error this code works: String response =
sc.getLastOperationContext().getMessageContext("In").getEnvelope().toString();
But when I run a succesful Axis2 call the same code gives the following
error: "java.lang.IllegalStateException: Can't process next node
because caching is disabled"
I tryed to enable cache like this, but it didn't work:
ServiceClient sc =
(ServiceClient)method_getServiceClient.invoke(objectReflect);
ServiceContext srv_context =
sc.getServiceContext();
srv_context.setCachingOperationContext(true);
OperationContext oc= new
OperationContext();
oc.setComplete(true);
srv_context.setLastOperationContext(oc);
Thank you