You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user-java@ibatis.apache.org by "Young, Alistair" <al...@logica.com> on 2009/01/12 11:54:04 UTC

iBATIS caching / transaction isolation question

Hello all,
 
I wonder if somebody could clarify for me how iBATIS caching works with
regards to transaction isolation.
 
Suppose I have a cache set up with is used when a "selectAllItems"
statement is invoked, and flushed when an "updateItem" statement is
invoked.
 
Suppose then that thread A starts a transaction, invokes updateItem and
then selectAllItems.  Then, before thread A completes the transaction,
thread B invokes selectAllItems.
 
Is transaction isolation maintained, or does thread B end up seeing the
(uncommitted) data that thread A has updated?
 
I should add that I haven't actually tried this yet - but I'd like to
know what the expected behaviour is before getting stuck in.
 
In our particular use case, we're making use of a custom
TransactionConfig (which is essentially the same as "EXTERNAL" but
handles connection creation slightly differently).  And we're not making
any explicit calls to the iBATIS transaction methods.
 
Many thanks!
 
 
Alistair.
 
 


Please help Logica to respect the environment by not printing this email  /  Merci d'aider Logica � pr�server l'environnement en �vitant d'imprimer ce mail /  Bitte drucken Sie diese Nachricht nicht aus und helfen Sie so Logica dabei die Umwelt zu schuetzen  /  Por favor ajude a Logica a respeitar o ambiente n�o imprimindo este correio electr�nico.



This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you.