• Denis Protivensky's avatar
    MDEV-33133: MDL conflict handling code should skip BF-aborted trxs · 235f33e3
    Denis Protivensky authored
    It's possible that MDL conflict handling code is called more
    than once for a transaction when:
    - it holds more than one conflicting MDL lock
    - reschedule_waiters() is executed,
    which results in repeated attempts to BF-abort already aborted
    transaction.
    In such situations, it might be that BF-aborting logic sees
    a partially rolled back transaction and erroneously decides
    on future actions for such a transaction.
    
    The specific situation tested and fixed is when a SR transaction
    applied in the node gets BF-aborted by a started TOI operation.
    It's then caught with the server transaction already rolled back,
    but with no MDL locks yet released. This caused wrong state
    detection for such a transaction during repeated MDL conflict
    handling code execution.
    Signed-off-by: default avatarJulius Goryavsky <julius.goryavsky@mariadb.com>
    235f33e3
wsrep_high_priority_service.cc 26 KB