Uploaded image for project: 'Infinispan'
  1. Infinispan
  2. ISPN-3599

CommitCommand with replayed PrepareCommand executes rollback and then commit

This issue belongs to an archived project. You can view it, but you can't modify it. Learn more

XMLWordPrintable

      During state-transfer in tx cache, the node can receive CommitCommand from other node. After the node gets transaction data for affected segments, it creates the transaction with missingLookedUpEntries=true and the CommitCommand can be executed.
      In this command's perform(...) the transaction is first marked as completed, then it enters the interceptor chain. There, the PrepareCommand is created in StateTransferInterceptor.visitCommitCommand but after this is processed the TxInterceptor finds out that the transaction is already completed and executes RollbackCommand, clearing locks etc.
      Nevertheless, StateTransferInterceptor executes the initial CommitCommand afterwards. I suspect that this may be executed without the locks held.
      Anyway, it is not correct to execute both commit and rollback on the same transaction.

              pruivo@redhat.com Pedro Ruivo
              rvansa1@redhat.com Radim Vansa (Inactive)
              Archiver:
              rhn-support-adongare Amol Dongare

                Created:
                Updated:
                Resolved:
                Archived: