Can I use the afterBegin, beforeCompletion, and afterCompletion methods in a BMP bean?

Dan Christopherson

The spec says no. Really, (IMHO) these don't translate well to the life of an entity bean for the following reasons:

  • afterBegin might not mean much since the entity might join the transaction long (computerwise) after the transaction is started.
  • Anything an entity bean needs to do 'beforeCompletion' should be done in ejbStore.
  • An entity bean really can't do much 'afterCompletion' - by definition, the entity's state is already wherever it needs to be (database, queue, legacy system, etc.)
You might want to re-evaluate what you're actually trying to do: chances are you're missing a key abstraction in your model.
0 Comments  (click to add your comment)
Comment and Contribute






(Maximum characters: 1200). You have 1200 characters left.



About | Sitemap | Contact