hbase-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yu Li (JIRA)" <j...@apache.org>
Subject [jira] [Created] (HBASE-15922) Fix waitForMaximumCurrentTasks logic in AsyncProcess
Date Tue, 31 May 2016 12:53:12 GMT
Yu Li created HBASE-15922:
-----------------------------

             Summary: Fix waitForMaximumCurrentTasks logic in AsyncProcess
                 Key: HBASE-15922
                 URL: https://issues.apache.org/jira/browse/HBASE-15922
             Project: HBase
          Issue Type: Bug
            Reporter: Yu Li


In current implementation of AsyncProcess#waitForMaximumCurrentTasks, we have below codes:
{code}
while ((currentInProgress = this.tasksInProgress.get()) > max) {
      ...
      try {
        synchronized (this.tasksInProgress) {
          if (tasksInProgress.get() != oldInProgress) break;
          this.tasksInProgress.wait(100);
        }
      } catch (InterruptedException e) {
        throw new InterruptedIOException("#" + id + ", interrupted." +
            " currentNumberOfTask=" + currentInProgress);
      }
}
{code}
Which will cause end of while loop if there's any task done inside one loop making {{taskInProgress.get()}}
no longer equals to {{oldInProgress}}

This is a regression issue caused by HBASE-11403 and only exists in branch-1/master branch,
we could easily see the difference comparing to latest 0.98 code.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message