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

Retrying RPC call for ModifyTableProcedure may get stuck

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Critical
    • Resolution: Unresolved
    • 2.0.0
    • None
    • Client, proc-v2
    • None

    Description

      Env: 2 masters, 1 RS.
      Steps to reproduce: Active master is killed while ModifyTableProcedure is executed.
      If the table has enough regions it may come that when the secondary master get active some of the regions may be closed, so once client retries the call to the new active master, a new ModifyTableProcedure is created and get stuck during MODIFY_TABLE_REOPEN_ALL_REGIONS state handling. That happens because:
      1. When we are retrying from client side, we call modifyTableAsync which create a procedure with a new nonce key:

               ModifyTableRequest request = RequestConverter.buildModifyTableRequest(
                  td.getTableName(), td, ng.getNonceGroup(), ng.newNonce());
      

      So on the server side, it's considered as a new procedure and starts executing immediately.
      2. When we are processing MODIFY_TABLE_REOPEN_ALL_REGIONS we create MoveRegionProcedure for each region, but it checks whether the region is online (and it's not), so it fails immediately, forcing the procedure to restart.

      ankit@apache.org saw a similar case when two concurrent ModifyTable procedures were running and got stuck in the similar way.

      Attachments

        1. HBASE-20657-1-branch-2.patch
          9 kB
          Sergey Soldatov
        2. HBASE-20657-2-branch-2.patch
          9 kB
          Sergey Soldatov
        3. HBASE-20657-3-branch-2.patch
          8 kB
          Sergey Soldatov
        4. HBASE-20657-4-master.patch
          8 kB
          Sergey Soldatov
        5. HBASE-20657-testcase-branch2.patch
          4 kB
          Sergey Soldatov

        Issue Links

          Activity

            People

              Unassigned Unassigned
              sergey.soldatov Sergey Soldatov
              Votes:
              0 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

                Created:
                Updated: