[open-ils-commits] r12613 - trunk/Open-ILS/src/perlmods/OpenILS/Utils (erickson)

svn at svn.open-ils.org svn at svn.open-ils.org
Thu Mar 19 12:36:05 EDT 2009


Author: erickson
Date: 2009-03-19 12:36:01 -0400 (Thu, 19 Mar 2009)
New Revision: 12613

Modified:
   trunk/Open-ILS/src/perlmods/OpenILS/Utils/CStoreEditor.pm
Log:
wrap authoritative rollbacks in a try so that a failed rollback won't leave a stale editor in the cache

Modified: trunk/Open-ILS/src/perlmods/OpenILS/Utils/CStoreEditor.pm
===================================================================
--- trunk/Open-ILS/src/perlmods/OpenILS/Utils/CStoreEditor.pm	2009-03-19 16:35:47 UTC (rev 12612)
+++ trunk/Open-ILS/src/perlmods/OpenILS/Utils/CStoreEditor.pm	2009-03-19 16:36:01 UTC (rev 12613)
@@ -25,7 +25,11 @@
 
 sub flush_forced_xacts {
     for my $k ( keys %xact_ed_cache ) {
-        $xact_ed_cache{$k}->rollback;
+        try {
+            $xact_ed_cache{$k}->rollback;
+        } catch Error with {
+            # rollback failed
+        };
         delete $xact_ed_cache{$k};
     }
 }



More information about the open-ils-commits mailing list