OpenLiberty / open-liberty

Open Liberty is a highly composable, fast to start, dynamic application server runtime environment
https://openliberty.io
Eclipse Public License 2.0
1.16k stars 599 forks source link

Serialization error in EJB call: no feedback #9209

Open tschurins opened 5 years ago

tschurins commented 5 years ago

Problem

We have an EJB returning a serializable object. By mistake, the returned object is a non static inner class, where the enclosing parent is not serializable. When we call this EJB, an exception is shown on the server side:

Exception in thread "Default Executor-thread-34" 
org.apache.yoko.orb.OB.AssertionFailed: Yoko encountered an internal error
    at org.apache.yoko.orb.OB.Assert._OB_assert(Assert.java:23)
    at org.apache.yoko.orb.OB.Downcall.setReplySCL(Downcall.java:229)
    at org.apache.yoko.orb.OB.CollocatedServer.upcallSystemException(CollocatedServer.java:427)
    at org.apache.yoko.orb.OB.Upcall.setSystemException(Upcall.java:450)
    at org.apache.yoko.orb.OB.PIUpcall.setSystemException(PIUpcall.java:156)
    at org.apache.yoko.orb.OBPortableServer.POA_impl._OB_dispatch(POA_impl.java:1678)
    at org.apache.yoko.orb.OB.DispatchRequest_impl.invoke(DispatchRequest_impl.java:56)
    at com.ibm.ws.transport.iiop.yoko.ExecutorDispatchStrategy$1.run(ExecutorDispatchStrategy.java:42)
    at com.ibm.ws.threading.internal.ExecutorServiceImpl$RunnableWrapper.run(ExecutorServiceImpl.java:239)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1160)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
    at java.lang.Thread.run(Thread.java:818)

but the client side never receives anything and keeps hanging.

Expected behaviour

The EJB client receives an exception with proper detail (this or that class is not serializable, &c.)

Details

joe-chacko commented 5 years ago

Thanks, @tschurins. It looks like there is an appropriate exception raised but we fail while trying return it due to this internal error. We will investigate further.

tschurins commented 5 years ago

See attached sample application: ol9209.zip

maven project creating a ear file that can be deployed in openliberty via docker (see readme.md) The servlet will call the EJB, causing the error.

gssandesh commented 4 months ago

@tschurins even i am facing the same problem can you help to resolve this issue