Uploaded image for project: 'HBase'
  1. HBase
  2. HBASE-2957

Release row lock when waiting for wal-sync

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Not A Problem
    • 0.20.0
    • None
    • regionserver, wal
    • None

    Description

      Is there a reason to hold on to the row-lock while waiting for the WAL-sync to be completed by the logSyncer thread?

      I think data consistency will be guaranteed even if the following happens (a) the row lock is held while the row is updated in memory (b) the row lock is released after queuing the KV record for WAL-syncing (c) the log-sync system guarantees that the log records for any given row are synced in order (d) the HBase client only receives a success notification after the sync completes (no change from the current state)

      I think this should be a huge win. For my use case, and I am sure for others, the handler thread spends the bulk of its row-lock critical section time waiting for sync to complete.

      Even if the log-sync system cannot guarantee the orderly completion of sync records, the "Don't hold row lock while waiting for sync" option should be available to HBase clients on a per request basis.

      Attachments

        Activity

          People

            Unassigned Unassigned
            khemani Prakash Khemani
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: