Hello Keith, thanks for your hint. It seems that the reuse solves my problems. Also thanks for the link, by searching I found nothing which seems to solve my problem, but the link is very useful for my development .
Kind regards Michael keith chapman wrote:
Hi Michael, I think I gave you a reply on a different thread. But as you have specified your client code here its more clearer to me now. In this scenario it might help if you set the following property [1], stub._getServiceClient().getOptions.setProperty(org.apache.axis2.transport.http.HTTPConstants.REUSE_HTTP_CLIENT, true); Thanks, Keith. [1] http://wso2.org/library/230#REUSE_HTTP_CLIENT On Thu, Aug 28, 2008 at 10:23 PM, Michael Sutter <[EMAIL PROTECTED]> wrote:Hello list, I have a strange problem with a Axis2 service and the corresponding client and maybe somebody can help me understanding what I'm doing wrong. I have a status service implemented with Axis2C running under a tomcat and the corresponding Java client for accessing the service. The java client is called every ten seconds from a thread and I can access the service without any problems. The problem is when the thread is running for some hours - normally between two or four I got a AxisFault with the message: Too many open files. First I thought that the service is implemented wrong, but this isn't the problem. I monitored the client and there I saw that on the client side the number of open files increases. The thread is implemented as follows: //instantiate the stub for the service statusStub = new Stub(..); after that I query the service every ten seconds until a boolean is set to false from outside while (!bStopThread) { resp = statusStub.getStatus(); staResp = resp.get_return(); Thread.currentThread().sleep(lStatusQueryTime); } When I do this I can monitor that the number of open files increases and so I get the AxisFault after some hours of runtime. Have I done something wrong in my code? Have I to release some objects or to instantiate the stub for every request? I don't understand whats my error. Kind regards Michael
