Hello,
In our project we are using a http client server for SOAP communication. The http client is based on Axis.
The http server responds to the client with the proper content-length indication. However, the http client is not closing the connection and keeping it alive. It looks like the Axis client is not able to read this and is timing out waiting for more messages. We get this error logged:
------------
AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: java.net.SocketTimeoutException: Read timed out
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace:java.net.SocketTimeoutException: Read timed out
at java.net.SocketInputStream.socketRead0(Native Method)
at java.net.SocketInputStream.read(SocketInputStream.java:129)
at java.io.BufferedInputStream.fill(BufferedInputStream.java:218)
at java.io.BufferedInputStream.read1(BufferedInputStream.java:256)
at java.io.BufferedInputStream.read(BufferedInputStream.java:313)
at java.io.FilterInputStream.read(FilterInputStream.java:111)
at org.apache.xerces.impl.XMLEntityManager$RewindableInputStream.read(Unknown Source)
at org.apache.xerces.impl.io.UTF8Reader.read(Unknown Source)
at org.apache.xerces.impl.XMLEntityScanner.load(Unknown Source)
at org.apache.xerces.impl.XMLEntityScanner.skipSpaces(Unknown Source)
at org.apache.xerces.impl.XMLDocumentScannerImpl$TrailingMiscDispatcher.dispatch(Unknown Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
at javax.xml.parsers.SAXParser.parse(Unknown Source)
at org.apache.axis.encoding.DeserializationContext.parse(DeserializationContext.java:227)
at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:696)
at org.apache.axis.Message.getSOAPEnvelope(Message.java:435)
at org.apache.axis.transport.http.HTTPSender.readFromSocket(HTTPSender.java:796)
at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:144)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at provgw.aucencrypter.wsdl.ACREENCRYPT_BindingStub.ACREENCRYPT_Processing(ACREENCRYPT_BindingStub.java:185)
at provgw.aucencrypter.AucEncrypter.reEncryptKey(AucEncrypter.java:112)
at provgw.processor.resolver.SpmlAuCAddRequestResolver.resolveRequest(SpmlAuCAddRequestResolver.java:89)
at provgw.processor.handler.ResolverPreHandler.doPreHandling(ResolverPreHandler.java:33)
at provgw.processor.handler.PreHandler.doPreHandling(PreHandler.java:32)
at provgw.processor.SpmlAddRequestProcessor.basicProcess(SpmlAddRequestProcessor.java:77)
at provgw.processor.SpmlRequestProcessor.processRequest(SpmlRequestProcessor.java:111)
at provgw.requestmanager.RequestManager$ProcessingTask.run(RequestManager.java:679)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
at java.lang.Thread.run(Thread.java:595)
{http://xml.apache.org/axis/}hostname:rxpgw1
----------------
The request received:
POST http://192.168.137.190:30600 HTTP/1.1
Connection: Keep-Alive
Content-Length: 567
Content-Type: text/xml
Host: 192.168.137.190
<?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>
**snip**
</soapenv:Body>
</soapenv:Envelope>
The response sent:
HTTP/1.1 200 OK
Content-Length: 695
Content-Type: text/html
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:AcReEncryptionKey="http://www.siemens.com/AcReEncryptionKey.wsdl" xmlns:acxsd="http://www.siemens.com/AcReEncryptionKey.xsd"><SOAP-ENV:Body>**snip**</SOAP-ENV:Body></SOAP-ENV:Envelope>
-------------------
Please let me know of any hints. What could be wrong in the usage? Are we missing some configuration/header information? Ideally, shouldn't the client stop reading after the content-length and pass the response up to the user without waiting further?
Thanks and regards,
Harish
------------------------------------------------------
Siemens Communication Software,
Bangalore, INDIA.
Phone: +91-80-2506 2323 (Direct)
+91-80-2506 2400 (Ext: 4159)
+91-9448452196 (Mobile)
email: [EMAIL PROTECTED]
-------------------------------------------------------
