Skip to content

Recovery fails to commit dangling transactions if there are no in-flight transactions #53

Open
@maxant

Description

@maxant

Test Case (BTM 2.1.4):

  • kill database before commit command can be sent to it (using debugger).
  • let thread continue to run
  • restart database
  • during recovery database reports transaction ID which is incomplete
  • Recoverer calls TransactionManagerServices.getTransactionManager().getOldestInFlightTransactionTimestamp() because transaction manager is running (line 137)
  • There are no in-flight transactions and so the TM returns Long.MIN_VALUE
  • Because the oldestInFlightTransactionTimestamp is now so low, the code on line 289 skips the dangling transaction which still needs to be committed.

The result is that the resource never has "commit" called again, unless BTM is restarted, or randomly a transaction is in-flight during recovery.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions