Uploaded image for project: 'controller'
  1. controller
  2. CONTROLLER-980

Clustering: Handle Shard transaction backwards compatibility

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved
    • Resolution: Done
    • Helium
    • None
    • mdsal
    • None
    • Operating System: All
      Platform: All

    • 2294

    Description

      Recent changes to the Shard 3-phase commit handling makes it incompatible with base Helium. We need to maintain backwards compatibility.

      The incompatibility is a result of a transactionId field added to the CanCommitTransaction, CommitTransaction, AbortTransaction protobuf messages.

      Solution:

      • In CanCommitTransaction, CommitTransaction, AbortTransaction protobuf messages make the transactionId field optional.
      • Add an optional version # field to the CreateTransaction protobuf message. A base Helium node wouldn't set the version so it will be 0.
      • Pass the CreateTransaction version # to the ShardTransaction.
      • On ReadyTransaction message, the ShardTransaction sends the version # with the ForwardedReadyTransaction message to the Shard.
      • In the Shard, on ForwardedReadyTransaction, if the version # < 1 (Helium-1 version), create a BackardsCompatibleThreePhaseCohort actor with the transactionId and pass its actor ref back in the response. Otherwise pass the Shard actor ref back as it currently does.
      • In BackardsCompatibleThreePhaseCommitCohort, on CanCommitTransaction, CommitTransaction, AbortTransaction messages, since the transactionId will be null or empty, create a new message with the cached transactionId and forward it to the Shard. Everything should work as is from there.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            tpantelis Tom Pantelis
            tpantelis Tom Pantelis
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: