[ 
https://issues.apache.org/jira/browse/HBASE-3744?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13017279#comment-13017279
 ] 

Ted Yu commented on HBASE-3744:
-------------------------------

Since AssignmentManager.assign() is outside BulkStartupAssigner and 
SingleServerBulkAssigner. It needs a startup parameter so that decision of 
whether to abort master can be made.
So BulkStartupAssigner and BulkTableAssigner would pass startup parameter to 
SingleServerBulkAssigner.
The only difference between BulkStartupAssigner and BulkTableAssigner is in 
their getUncaughtExceptionHandler() method. Meaning, we can write this:
{code}
  static class BulkTableAssigner extends BulkStartupAssigner {
    @Override
    protected UncaughtExceptionHandler getUncaughtExceptionHandler() {
      return new UncaughtExceptionHandler() {
        @Override
        public void uncaughtException(Thread t, Throwable e) {
          LOG.error("Error assigning regions in " + t.getName(), e);            
        }
      };
    }
  }
{code}

> createTable blocks until all regions are out of transition
> ----------------------------------------------------------
>
>                 Key: HBASE-3744
>                 URL: https://issues.apache.org/jira/browse/HBASE-3744
>             Project: HBase
>          Issue Type: Bug
>          Components: master
>    Affects Versions: 0.90.1
>            Reporter: Todd Lipcon
>            Assignee: Ted Yu
>            Priority: Critical
>             Fix For: 0.92.0
>
>         Attachments: 3744.txt, 3744.txt
>
>
> In HBASE-3305, the behavior of createTable was changed and introduced this 
> bug: createTable now blocks until all regions have been assigned, since it 
> uses BulkStartupAssigner. BulkStartupAssigner.waitUntilDone calls 
> assignmentManager.waitUntilNoRegionsInTransition, which waits across all 
> regions, not just the regions of the table that has just been created.
> We saw an issue where one table had a region which was unable to be opened, 
> so it was stuck in RegionsInTransition permanently (every open was failing). 
> Since this was the case, waitUntilDone would always block indefinitely even 
> though the newly created table had been assigned.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to