Using 2.0.1, creating a client from a large wsdl (~1 MB) in my
classpath using generated stubs increases memory usage by about 20
MB, which never gets garbage collected. Later clients created from
the same WSDL url cause similar increases until I get an out of
memory condition.
static {
WSDL_URL = MyService.class.getClassLoader().getResource
("myService.wsdl");
SERVICE_QNAME = new QName("urn:myService", "MyService");
}
MyService service = new MyService(WSDL_URL, SERVICE_QNAME);
MyPort client = service.getMyPort();
BindingProvider provider = (BindingProvider)client;
provider.getRequestContext().put
(BindingProvider.ENDPOINT_ADDRESS_PROPERTY, endpoint.getURL());
Client c = ClientProxy.getClient(client);
HTTPConduit conduit = (HTTPConduit)c.getConduit();
conduit.getClient().setAllowChunking(false);
// ... SSL setup too ...
Working through a heap dump now, but does this look familiar to anyone?
--Joe