Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Locking with Entity Beans  RSS feed

Abhinav Srivastava
Ranch Hand
Posts: 354
Eclipse IDE Java Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Consider this sequence of events
Tx 1 : Loads Entiry A
TX 1: Update Entity A
Tx 2: Executes SQL Query to Read a row which is affected by Tx 1
Tx 1: commits

Should TX2 be locked out until TX1 is committed (it seems so) ? I am working in Websphere/DB2 environment with access intent policy wsPessimisticUpdateNoCollision. I am trying to find a way out of the locking situation. Would the behaviour be any different if instead of using direct SQL, we use EJB lookups?
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!