cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Djoser <>
Subject Pool of instances exceeds maximum instance count
Date Wed, 27 Oct 2010 09:40:25 GMT


I have developed a standalone web service with CXF and it's currently
running in production. When there are lots of requests simultaneously, the
response time of the service is sometimes too long (it rarely happens
though). So I'm trying to create a pool of 10 instances. The problem is that
although I specify a maximum value of 10 instances in the
org.apache.cxf.service.invoker.PooledFactory constructor, the service
creates an instance for each request, regardless of the maximum value. If 20
requests arrive at the same time, 20 instances are created. I absolutely
need to limit the number of instances. Is there something wrong in my code ?

Factory factory = new PerRequestFactory(XpcmsResponder.class);
factory = new PooledFactory(factory, 10, false);
JAXWSMethodInvoker invoker = new JAXWSMethodInvoker(factory);
JaxWsServerFactoryBean factoryBean = new JaxWsServerFactoryBean();

View this message in context:
Sent from the cxf-user mailing list archive at

View raw message