• Post Reply Bookmark Topic Watch Topic
  • New Topic

Problem in calling an EJB method from a delegate class  RSS feed

 
DinesKumar Murugan
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In Our application we encountered with the following exception while a Delegate class calls a EJB Bean class to update a record in DB.

While calling the delegate we are passing 3 parameters namely H2HProperties object, a String object and a Connection object and among three parameters the H2HProperties is a value object class which already implements Serializable interface. But still face the issue.

So please someone help me who has already faced this kind of problem in your application.

2010-02-08 18:43:24,160 ERROR com.crimsonlogic.trade.tdec.sau.business.TDECDelegate - initH2HMessageProcess(H2HProperties h2hProp)
javax.transaction.TransactionRolledbackException: EJB Exception: : java.io.NotSerializableException: weblogic.transaction.internal.ServerTransactionImpl
at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1054)
at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1330)
at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1302)
at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1245)
at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1052)
at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:278)
at weblogic.rmi.internal.CBVOutputStream.writeObject(CBVOutputStream.java:78)
at weblogic.rmi.internal.CBVWrapper.copy(CBVWrapper.java:47)
at com.crimsonlogic.trade.tdec.sau.ejb.TDECMsgSvcBean_6t19qe_EOImpl_CBV.updateTransStatus(Unknown Source)
at com.crimsonlogic.trade.tdec.sau.business.TDECDelegate.updateTransStatus(TDECDelegate.java:250)
at com.crimsonlogic.trade.tdec.sau.business.H2HTDecSubManager.processH2HTDecSub(H2HTDecSubManager.java:293)
at com.crimsonlogic.trade.tdec.sau.business.H2HTDecSubManager.processH2HMsg(H2HTDecSubManager.java:52)
at com.crimsonlogic.trade.tdec.sau.ejb.TDECMsgSvcBean.processH2HMsg(TDECMsgSvcBean.java:969)
at com.crimsonlogic.trade.tdec.sau.ejb.TDECMsgSvcBean.initH2HMessageProcess(TDECMsgSvcBean.java:881)
at com.crimsonlogic.trade.tdec.sau.ejb.TDECMsgSvcBean_6t19qe_EOImpl.initH2HMessageProcess(TDECMsgSvcBean_6t19qe_EOImpl.java:208)
at com.crimsonlogic.trade.tdec.sau.ejb.TDECMsgSvcBean_6t19qe_EOImpl_CBV.initH2HMessageProcess(Unknown Source)
at com.crimsonlogic.trade.tdec.sau.business.TDECDelegate.initH2HMessageProcess(TDECDelegate.java:222)
at com.crimsonlogic.trade.sau.msg.ejb.MsgSvcBean.processH2HMsg(MsgSvcBean.java:622)
at com.crimsonlogic.trade.sau.msg.ejb.MsgSvcBean_5z2zq6_EOImpl.processH2HMsg(MsgSvcBean_5z2zq6_EOImpl.java:694)
at com.crimsonlogic.trade.sau.msg.ejb.H2HMBean.onMessage(H2HMBean.java:83)
at weblogic.ejb20.internal.MDListener.execute(MDListener.java:382)
at weblogic.ejb20.internal.MDListener.transactionalOnMessage(MDListener.java:316)
at weblogic.ejb20.internal.MDListener.onMessage(MDListener.java:281)
at com.ibm.mq.jms.MQQueueReceiver.receiveAsync(MQQueueReceiver.java:706)
at com.ibm.mq.jms.SessionAsyncHelper.run(SessionAsyncHelper.java:362)
at java.lang.Thread.run(Thread.java:536)
--------------- nested within: ------------------
weblogic.utils.AssertionError: ***** ASSERTION FAILED ***** - with nested exception:
[java.io.NotSerializableException: weblogic.transaction.internal.ServerTransactionImpl]
at weblogic.rmi.internal.CBVWrapper.copy(CBVWrapper.java:55)
at com.crimsonlogic.trade.tdec.sau.ejb.TDECMsgSvcBean_6t19qe_EOImpl_CBV.updateTransStatus(Unknown Source)
at com.crimsonlogic.trade.tdec.sau.business.TDECDelegate.updateTransStatus(TDECDelegate.java:250)
at com.crimsonlogic.trade.tdec.sau.business.H2HTDecSubManager.processH2HTDecSub(H2HTDecSubManager.java:293)
at com.crimsonlogic.trade.tdec.sau.business.H2HTDecSubManager.processH2HMsg(H2HTDecSubManager.java:52)
at com.crimsonlogic.trade.tdec.sau.ejb.TDECMsgSvcBean.processH2HMsg(TDECMsgSvcBean.java:969)
at com.crimsonlogic.trade.tdec.sau.ejb.TDECMsgSvcBean.initH2HMessageProcess(TDECMsgSvcBean.java:881)
at com.crimsonlogic.trade.tdec.sau.ejb.TDECMsgSvcBean_6t19qe_EOImpl.initH2HMessageProcess(TDECMsgSvcBean_6t19qe_EOImpl.java:208)
at com.crimsonlogic.trade.tdec.sau.ejb.TDECMsgSvcBean_6t19qe_EOImpl_CBV.initH2HMessageProcess(Unknown Source)
at com.crimsonlogic.trade.tdec.sau.business.TDECDelegate.initH2HMessageProcess(TDECDelegate.java:222)
at com.crimsonlogic.trade.sau.msg.ejb.MsgSvcBean.processH2HMsg(MsgSvcBean.java:622)
at com.crimsonlogic.trade.sau.msg.ejb.MsgSvcBean_5z2zq6_EOImpl.processH2HMsg(MsgSvcBean_5z2zq6_EOImpl.java:694)
at com.crimsonlogic.trade.sau.msg.ejb.H2HMBean.onMessage(H2HMBean.java:83)
at weblogic.ejb20.internal.MDListener.execute(MDListener.java:382)
at weblogic.ejb20.internal.MDListener.transactionalOnMessage(MDListener.java:316)
at weblogic.ejb20.internal.MDListener.onMessage(MDListener.java:281)
at com.ibm.mq.jms.MQQueueReceiver.receiveAsync(MQQueueReceiver.java:706)
at com.ibm.mq.jms.SessionAsyncHelper.run(SessionAsyncHelper.java:362)
at java.lang.Thread.run(Thread.java:536)
; nested exception is:



Regards,
Dinesh.
 
Marco Ehrentreich
best scout
Bartender
Posts: 1294
IntelliJ IDE Java Scala
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi DinesKumar,

unfortunately I'm not familiar with Weblogic but as the stacktrace says there's obviously still a problem when serializing H2HProperties. Are you sure that the whole object graph of H2HProperties is Serializable? I guess it won't be sufficient if only H2HProperties implements Serializable and some child or composite classes do not.
Or did you provide your own application logic for the writeObject() method which could be causing the problem?

Marco
 
DinesKumar Murugan
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Thanks a lot for the reply.

Yes the whole H2HProperties class is serialized and it has no sub classes. Also I didn't write any own application logic for writeObject() method.

Regards,
Dinesh.

 
ramprasad madathil
Ranch Hand
Posts: 489
Eclipse IDE Java Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you using the values() or keySet() method to pass or return data? This thread - http://www.coderanch.com/t/479702/EJB-Other-Java-EE-Technologies/java/do-figure-out-what-not will help.

ram.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!