Browse Source
While this won't prevent the deadlock, it should catch the case where a deadlock causes the DB update to fail and provide feedback to the user and rollback the transaction I don't know how to trigger the deadlock, I can only confirm that we see it, and that this should catch it. To test: 1 - Apply patches 2 - Checkout several items to a patron 3 - Confirm that 'Renew all' feature continues to work as expected and all items are renewed Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>21.05.x
3 changed files with 32 additions and 2 deletions
@ -0,0 +1,15 @@ |
|||
package Koha::Exceptions::Checkout; |
|||
|
|||
use Modern::Perl; |
|||
|
|||
use Exception::Class ( |
|||
'Koha::Exceptions::Checkout' => { |
|||
description => "Something went wrong!" |
|||
}, |
|||
'Koha::Exceptions::Checkout::FailedRenewal' => { |
|||
isa => 'Koha::Exceptions::Checkout', |
|||
description => "Renewing checkout failed" |
|||
}, |
|||
); |
|||
|
|||
1; |
Loading…
Reference in new issue