File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Web Services and the fly likes Axis invoke() freezes Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "Axis invoke() freezes" Watch "Axis invoke() freezes" New topic

Axis invoke() freezes

stefan bungert

Joined: Oct 29, 2005
Posts: 5
Hi all!

I have problems invoking a Web Service with AXIS.
When I call a web service which is on localhost, the process freezes when invoke() is called.
SOAPEnvelope response = createCall(serverURI).invoke(request);

After trying a few times I opened TCP Monitor to check communication. The whole traffic is very well, I see the request which seems correct. I see the response coming in, which is also correct.
Then I clicked on the remove Button on TCP Monitor which then caused my program to continue!
I don't know what that means, but maybe you have expreienced the same.
I will paste the soap message request and response, as I said, the program only continues when I press the "remove selected" or "remove all" button in the Axis TCP Monitor. The program can also handle the response well.

By the way, I have another tool to invoke the same request, which works (without clicking that button)
I have not acivated any proxy or delay in TCP Monitor

any help would be great!
thanks in advance
Stefan B.

POST /opcxmlda/wago.opcserver.modbustcp.da.1 HTTP/1.0
Content-Type: text/xml; charset=utf-8
Accept: application/soap+xml, application/dime, multipart/related, text/*
User-Agent: Axis/1.3
Cache-Control: no-cache
Pragma: no-cache
SOAPAction: ""
Content-Length: 581

<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope xmlns:soapenv="" xmlns:xsd="" xmlns:xsi="" xmlns:xmlda="">
<soapenv ptions ReturnItemTime="true" ReturnItemName="true" ClientRequestHandle="" LocaleID="en-us"/>
<soapenv:ItemList MaxAge="1000">
<soapenv:Items ItemPath="" ItemName="i-for-T/Peak_Max" ClientItemHandle=""/>


HTTP/1.1 200 OK
Server: dOPC XGate 2.06
Content-Type: text/xml; charset="utf-8"
Content-Length: 636
Connection: keep-alive

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="" xmlns:xsd="" xmlns:xsi="">
<ReadResponse xmlns="">
<ReadResult RcvTime="2006-02-22T19:41:36.078+01:00" ReplyTime="2006-02-22T19:41:36.093+01:00" RevisedLocaleID="en" ServerState="running"/>
<Items ItemName="i-for-T/Peak_Max" Timestamp="2006-02-22T19:41:36.093+01:00">
<Value xsi:type="xsd:unsignedShort">85</Value>
William Brogden
Author and all-around good cowpoke

Joined: Mar 22, 2000
Posts: 13037
Is it possible that the service is not closing the output stream, thus the client is waiting for more data?
stefan bungert

Joined: Oct 29, 2005
Posts: 5
Yes it is possible, but..

I succesfully sent a message directly to the webserver over a socket. I took a request message from the tcpmonitor and pasted it into the webserver stream.

Then the request came back on the stream which I could print on the console.

that means the server works fine, the axis somehow has problems reading the response stream...

what else can i do?

I agree. Here's the link:
subject: Axis invoke() freezes
It's not a secret anymore!