kvserver: don't PUSH_ABORT encountered intent txns during GC #65777
Labels
A-kv-transactions
Relating to MVCC and the transactional model.
C-bug
Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.
When the GC queue is cleaning up intents, it appears to push their txns with
PUSH_ABORT
:cockroach/pkg/kv/kvserver/gc_queue.go
Lines 476 to 477 in 024ad2f
This can be very disruptive, and also block for a significant time. It does have an age threshold:
cockroach/pkg/kv/kvserver/gc/gc.go
Lines 48 to 53 in 89c91e7
But aborting txns that have been doing work for >2h seems particularly disruptive.
I suggest we use
PUSH_TOUCH
here, to leave active txns alone. That will also kick off txn recovery forSTAGING
txns if the txn liveness has expired:cockroach/pkg/kv/kvserver/batcheval/cmd_push_txn.go
Lines 277 to 281 in 759fdac
We should also consider simply dropping
IntentAgeThreshold
and rely solely on the intent txn status if we can efficiently distinguish between active and stale intents via other means.The text was updated successfully, but these errors were encountered: