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

StateTransfer's PutKeyValueCommand may trigger remote get

    Details

      Description

      In TX mode with write skew check on, ST executing puts may trigger a remote get.
      The condition in TxDistributionInterceptor.handleTxWriteCommand should probably be switched from

      if (ctx.isOriginLocal() && !skipRemoteGet || command.isConditional() || shouldFetchRemoteValuesForWriteSkewCheck(ctx, command))
           remoteGetBeforeWrite(ctx, command, recipientGenerator);
      

      to

      if (!skipRemoteGet && (ctx.isOriginLocal() || command.isConditional() || shouldFetchRemoteValuesForWriteSkewCheck(ctx, command)))
           remoteGetBeforeWrite(ctx, command, recipientGenerator);
      

      EDIT:
      I have also registered a situation where the Prepare/Commit command was executed remotely from within the ST because the topology has changed during the remote get. This should be avoided as well.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                dan.berindei Dan Berindei
                Reporter:
                rvansa Radim Vansa
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: