In Delegate class getReplyGroup method is not thread safe: private ReplyGroup getReplyGroup (ClientConnection connectionToUse) This part of code can cause that if 2 threads are works in parallel one can works with ReplyGroup that didn't pass the postInit method: ReplyGroup g = new ReplyGroup (this, profile); group = groups.putIfAbsent (profile, g); if (group == null) { group = g; group.postInit(); } Why the postInit method is not part of the constructor? This would have solve the problem? See below stack trace of the exception I got because of this problem: (got NullPointerException) at org.omg.CORBA.portable.ObjectImpl._invoke(ObjectImpl.java:475) at org.jacorb.orb.Delegate.invoke(Delegate.java:1232) at org.jacorb.orb.Delegate.invoke_internal(Delegate.java:1244) at org.jacorb.orb.Delegate._invoke_internal(Delegate.java:1415) at org.jacorb.orb.ReplyGroup.addHolder(ReplyGroup.java:92) Thanks.
Can you reproduce this easily? Can you provide a test case?
Created attachment 463 [details] example
Comment on attachment 463 [details] example Simple example - just run it to reproduce the problem
Verified ; thanks for the test case!
Hi, We are currently looks for a work around until the bug will be fixed. We thought about adding some dummy method to each service and call it after the stub creation. Do you think this will overcome the problem? Thanks
Apologies for the delay in merging your fix. Fix is now committed to head with SHA f2585e489eb26e32d6e8b68409cd27895a433edc
Thanks for the fast respone. Do you know when I can expect for a new version that contains the fix? I would like to understand if it worth for me to write code that overcome the problem or wait for the next release. Thanks again.
Currently we don't have immediate plans for a micro release. If several fixes are submitted then the plans may change. You could take the source from https://github.com/JacORB/JacORB/ and compile it yourself if you wish.