JBoss eap6 vs Metro Memory consumption WS Port

Latest response

I am migrating from JBoss as 5 using metro ws to JBoss EAP 6 with JAX-WS running on JBossws-cxf stack. Whn comparing the memory performance, I have seen that there is a huge difference between the memory allocated by metro and the allocated memory by JBoss.
Metro is jsut createing a seiStub wich didn't retain too much memory. Using JBossws-3.4, the memory retained by a port is about 2,871,416. This retained memory is reduced to 1,539,704 in JBoss eap 6.
I'am using a port pool in my application which causes the allocation of too much memory.

Why all these difference in the allocated memory between metro and JBoss.
Is there any solution to reduce this memory consumption.



With Apache CXF you don't need to pool your Port objects as they are thread safe [1]. From what you've written JBoss is using less memory in the later version?

If you think you are having memory issues, I'd suggest raising a support case with some heap dumps attached so we can take a look at them.

[1] http://cxf.apache.org/faq.html#FAQ-AreJAXWSclientproxiesthreadsafe%3F

can two threads use the same port at the same time! without having functional problem.

Again, from the CXF documentation [1]

"For most "simple" use cases, you can use CXF proxies on multiple threads."

There is lists some exceptions where the proxy objects are NOT thread safe but like the above statement says, for most "simple" use cases, yes you can use multiple threads on the same port.

[1] http://cxf.apache.org/faq.html#FAQ-AreJAXWSclientproxiesthreadsafe%3F