0 Replies Latest reply on Apr 19, 2004 3:17 AM by Sascha Kulawk

    Isolation Problem - One Transaction affects anotherone

    Sascha Kulawk Newbie


      I've a really strange problem.
      I have a long term Transaction (A) which takes about 5 minutes. During this transaction some other read access from a website are running and maybe also using beans that are changed / deleted though transaction A.
      For showing a website it is maybe not really necessary, that it will be blocked until the transaction A is ready, but however.
      The mysterious thing about this takes place if transaction A is finished and afterwords one of the blocked transactions will be resumed - in my case this transaction will access a bean that has been deleted and afterwords a new bean with the same primary key has been created.
      I got following error:
      Update failed. Expected one affected row: rowsAffected=0id=224108
      (Note, this is a read-only access!)

      Strange enough, but the strangest thing about this is, that the transaction A has got a rollback as well - but without any notice! (The last statement in the transaction A will be shown in the log, the error occures afterwords and the stacktrace is from one website-access transaction.

      Can anybody explain me the fault here?
      I've also tried to change the isolation level to READ_UNCOMITTED but in this case every website access is throwing an exception during the transaction A. All entity beans are "Instance per Transaction CMP 2.x".

      Thank you for your help,