As you can see the request are completely different.
In one case, you send an xml as a string (using axis),
and you send the xml directly using servicemix.
You have to send a correct request.  But it sounds a bit
weird to send an xml encoded in a string to a web service.

On 2/8/07, Anthony <[EMAIL PROTECTED]> wrote:

hi Guillaume, i intercepted the calls using tcpmon and these are the results:


my java request using axis:
POST /eai-web-1.0/services/EaiService HTTP/1.0
Content-Type: text/xml; charset=utf-8
Accept: application/soap+xml, application/dime, multipart/related, text/*
User-Agent: Axis/1.4
Host: localhost:80
Cache-Control: no-cache
Pragma: no-cache
SOAPAction: ""
Content-Length: 1365

<?xml version="1.0" encoding="UTF-8"?><soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";><soapenv:Body><ns1:processSessionAggregation
soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/";
xmlns:ns1="EaiService"><msg xsi:type="xsd:string">&lt;?xml
version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
&lt;xb:esbMessage
xmlns:xb=&quot;http://www.rmb.co.za/eai/common/xmlbeans&quot;&gt;
  &lt;esbHeader&gt;
    &lt;sourceSystem&gt;SOME_SYSTEM&lt;/sourceSystem&gt;
    &lt;date&gt;2007-02-08T13:57:37.228+02:00&lt;/date&gt;
    &lt;esbAggregationProps&gt;

&lt;sessionId&gt;ecf76178-f0b5-4244-8294-4dac9ae30fbc&lt;/sessionId&gt;
      &lt;msgType&gt;AGGREGATION-START&lt;/msgType&gt;

&lt;destination&gt;http://www.dummyDestination.co.za&lt;/destination&gt;
      &lt;timeoutSecs&gt;9999&lt;/timeoutSecs&gt;
      &lt;maxBatchSize&gt;1000&lt;/maxBatchSize&gt;
      &lt;totalMessages&gt;3&lt;/totalMessages&gt;
    &lt;/esbAggregationProps&gt;
  &lt;/esbHeader&gt;
  &lt;esbBody&gt;
    &lt;body xsi:nil=&quot;true&quot;
xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot;/&gt;
  &lt;/esbBody&gt;
&lt;/xb:esbMessage&gt;</msg></ns1:processSessionAggregation></soapenv:Body></soapenv:Envelope>


the correct response from the axis web service:
HTTP/1.1 200 OK
Content-Type: text/xml;charset=utf-8
Date: Thu, 08 Feb 2007 11:57:37 GMT
Server: Apache-Coyote/1.1
Connection: close

<?xml version="1.0" encoding="utf-8"?><soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";><soapenv:Body><ns1:processSessionAggregationResponse
soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/";
xmlns:ns1="EaiService"><returnqname xsi:type="xsd:string">&lt;xb:esbMessage
xmlns:xb=&quot;http://www.rmb.co.za/eai/common/xmlbeans&quot;&gt;
  &lt;esbHeader&gt;
    &lt;sourceSystem&gt;SOME_SYSTEM&lt;/sourceSystem&gt;
    &lt;date&gt;2007-02-08T13:57:37.228+02:00&lt;/date&gt;
    &lt;esbAggregationProps&gt;

&lt;sessionId&gt;ecf76178-f0b5-4244-8294-4dac9ae30fbc&lt;/sessionId&gt;
      &lt;msgType&gt;AGGREGATION-START-ACK&lt;/msgType&gt;

&lt;destination&gt;http://www.dummyDestination.co.za&lt;/destination&gt;
      &lt;timeoutSecs&gt;9999&lt;/timeoutSecs&gt;
      &lt;maxBatchSize&gt;1000&lt;/maxBatchSize&gt;
      &lt;totalMessages&gt;3&lt;/totalMessages&gt;
    &lt;/esbAggregationProps&gt;
  &lt;/esbHeader&gt;
  &lt;esbBody&gt;
    &lt;body xsi:nil=&quot;true&quot;
xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot;/&gt;
  &lt;/esbBody&gt;
&lt;/xb:esbMessage&gt;</returnqname></ns1:processSessionAggregationResponse></soapenv:Body></soapenv:Envelope>


the servicemix http provider request:
POST /eai-web-1.0/services/EaiService HTTP/1.1
Content-Type: text/xml
Content-Length: 807
SOAPAction: processSessionAggregation
User-Agent: Jakarta Commons-HttpClient/3.0
Host: localhost

<?xml version='1.0' encoding='UTF-8'?><env:Envelope
xmlns:env="http://schemas.xmlsoap.org/soap/envelope/";><env:Body><xb:esbMessage
xmlns:xb="http://www.rmb.co.za/eai/common/xmlbeans";>
  <esbHeader>
    <sourceSystem>Calypso</sourceSystem>
    <date>2007-02-08T13:58:34.605+02:00</date>
    <esbAggregationProps>
      <sessionId>61cc3b55-8dd8-437c-b6e9-685e4c13c9ce</sessionId>
      <msgType>AGGREGATION-START</msgType>
      <destination>some destination</destination>
      <timeoutSecs>-1</timeoutSecs>
      <maxBatchSize>0</maxBatchSize>
      <sequenceNo>0</sequenceNo>
      <totalMessages>0</totalMessages>
    </esbAggregationProps>
  </esbHeader>
  <esbBody>
    <body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xsi:nil="true" />
  </esbBody>
</xb:esbMessage></env:Body></env:Envelope>


the response that contains the error:
HTTP/1.1 500 Internal Server Error
Content-Type: text/xml;charset=utf-8
Transfer-Encoding: chunked
Date: Thu, 08 Feb 2007 11:58:34 GMT
Server: Apache-Coyote/1.1
Connection: close

257
<?xml version="1.0" encoding="UTF-8"?><soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/";
xmlns:xsd="http://www.w3.org/2001/XMLSchema";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";><soapenv:Body><soapenv:Fault><faultcode>soapenv:Server.userException</faultcode><faultstring>org.xml.sax.SAXException:
SimpleDeserializer encountered a child element, which is NOT expected, in
something it was trying to deserialize.</faultstring><detail><ns1:hostname
xmlns:ns1="http://xml.apache.org/axis/";>HGO1</ns1:hostname></detail></soapenv:Fault></soapenv:Body></soapenv:Envelope>
0


any idea what can cause this SAXException?


thanks!
--
View this message in context: 
http://www.nabble.com/Calling-external-web-service-tf3159837s12049.html#a8864358
Sent from the ServiceMix - User mailing list archive at Nabble.com.




--
Cheers,
Guillaume Nodet
------------------------
Architect, LogicBlaze (http://www.logicblaze.com/)
Blog: http://gnodet.blogspot.com/

Reply via email to