MT#63500 skip cdr if failing to acquire contract lock

to avoid rateomat exiting, we now skip a CDR if it fails to
acquire all involved contract row locks rather than bailing out.

Change-Id: Ibbe3b4e0c40008aa033673a7ef3fa98d54945417
(cherry picked from commit 840ccb33f5)
mr12.5
Rene Krenn 12 months ago
parent eeb6279f16
commit 57a827702e

@ -3721,7 +3721,13 @@ sub main {
# the whole transaction. thus locking contract rows for preventing
# concurrent catchups will be our very first SQL statement in the
# billingdb transaction:
lock_contracts($cdr);
eval { lock_contracts($cdr); };
if ($@) {
commit_transaction($acctdbh);
commit_transaction($billdbh);
check_shutdown() and last BATCH;
next CDR;
}
begin_transaction($provdbh);
begin_transaction($dupdbh);

Loading…
Cancel
Save