cooldev
cooldev

Reputation: 527

EJB: Remote transaction propogation in websphere liberty

I am working on migrating ejb application from traditional websphere 9 to liberty.

My application source code uses remote transaction propogation. Is remote transaction propogation supported in websphere liberty? Any workarounds?

Upvotes: 0

Views: 629

Answers (1)

Gas
Gas

Reputation: 18030

No, Liberty doesn't support transaction propagation. Check this page - Using enterprise JavaBeans with remote interfaces on Liberty.

Liberty does not support outbound or inbound transaction propagation... The client can start the EJB if the EJB is changed to use the RequiresNew or NotSupported transaction attributes. However, the transactional work that is done by the EJB is not committed as part of the transactions of the client.

So my typical recommendations for such case are:

  • check if you really need remote interfaces - this is often legacy code, which had remote interfaces by default, but in reality all calls are local (same app/jvm) - if true, then switch to local interfaces
  • check if you can 'safely' change the Required to RequiresNew or NotSupported, without impacting application logic
  • if you cannot use any of above, you will have to redesign/rearchitecture your app, or add some custom code to handle manually these transactions, that now will be separate.

Upvotes: 1

Related Questions