Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-12686

TxnHandler.checkLock(CheckLockRequest) perf improvements

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.3.0
    • None
    • Transactions
    • None

    Description

      CheckLockRequest should include txnid since the caller should always know this (if there is a txn).
      This would make getTxnIdFromLockId() call unnecessary.

      checkLock() is usually called much more often (especially at the beginning of exponential back off sequence), thus a lot of these heartbeats are overkill. Could also include a time (in ms) since last checkLock() was called and use that to decide to heartbeat or not.

      In fact, if we made heartbeat in DbTxnManager start right after locks in "W" state are inserted, heartbeat in checkLock() would not be needed at all.
      This would be the best solution but need to make sure that heartbeating is started appropriately in Streaming API - currently it does not. It requires the client to start heartbeating.

      Attachments

        Issue Links

          There are no Sub-Tasks for this issue.

          Activity

            People

              Unassigned Unassigned
              ekoifman Eugene Koifman
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: