[jboss-dev-forums] [Design of JBoss Serialization] - Using customized RMI socket factory with JBOSSSerialization
yaishb
do-not-reply at jboss.com
Wed Sep 10 16:31:05 EDT 2008
Hello all,
We are trying to imrove RMI performance in one client-server RMI application. we customized RMI socket factory (client and server), which uses customized Socket and ServerSocket, which use JBOSSObjectInputStraem and JBOSSObjectOutputStraem (is this the correct way to use jboss serialization in RMI?).
One flow in the client application invoke many time Naming.lookup() on the server rmi registry.
If not using the customized socket factory (hence not using jboss serialization) - everything works great. If using the custmozied socket factories, OutOfMemoryError is raised:
java.lang.OutOfMemoryError: unable to create new native thread
at java.lang.Thread.start0(Native Method)
at java.lang.Thread.start(Thread.java:597)
at sun.rmi.transport.DGCClient$EndpointEntry.(DGCClient.java:231)
at sun.rmi.transport.DGCClient$EndpointEntry.lookup(DGCClient.java:202)
at sun.rmi.transport.DGCClient.registerRefs(DGCClient.java:120)
at sun.rmi.transport.ConnectionInputStream.registerRefs(ConnectionInputStream.java:80)
at sun.rmi.transport.StreamRemoteCall.releaseInputStream(StreamRemoteCall.java:138)
at sun.rmi.transport.StreamRemoteCall.done(StreamRemoteCall.java:292)
at sun.rmi.server.UnicastRef.done(UnicastRef.java:431)
at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
at java.rmi.Naming.lookup(Naming.java:84)
at com.commons.pattern.barakota.HashRAMRMIClient.lookup(HashRAMRMIClient.java:483)
at com.commons.pattern.css.rmi.RMICSSClient.initializeDelegatesPool(RMICSSClient.java:70)
at com.commons.pattern.css.CSSPeer.init(CSSPeer.java:35)
at com.commons.pattern.barakota.HashRAMRMIClient.(HashRAMRMIClient.java:36)
at com.storing.context.StoringContext$HashRAMBooter.run(StoringContext.java:908)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
at java.lang.Thread.run(Thread.java:619)
Can you please assist with debugging this behaviour?
Thanks,
Barak.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4175695#4175695
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4175695
More information about the jboss-dev-forums
mailing list