You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by ap...@apache.org on 2015/09/04 03:38:31 UTC
[6/6] hbase git commit: HBASE-14359 HTable#close will hang forever if
unchecked error/exception thrown in AsyncProcess#sendMultiAction (Victor Xu)
HBASE-14359 HTable#close will hang forever if unchecked error/exception thrown in AsyncProcess#sendMultiAction (Victor Xu)
Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/3e68b1e9
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/3e68b1e9
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/3e68b1e9
Branch: refs/heads/0.98
Commit: 3e68b1e9957df83173730b00bdf8dd5159e1a1a9
Parents: 86d39a3
Author: Andrew Purtell <ap...@apache.org>
Authored: Thu Sep 3 17:48:45 2015 -0700
Committer: Andrew Purtell <ap...@apache.org>
Committed: Thu Sep 3 18:04:46 2015 -0700
----------------------------------------------------------------------
.../apache/hadoop/hbase/client/AsyncProcess.java | 17 +++++++++++------
1 file changed, 11 insertions(+), 6 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/hbase/blob/3e68b1e9/hbase-client/src/main/java/org/apache/hadoop/hbase/client/AsyncProcess.java
----------------------------------------------------------------------
diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/AsyncProcess.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/AsyncProcess.java
index d68668b..841b757 100644
--- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/AsyncProcess.java
+++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/AsyncProcess.java
@@ -563,15 +563,20 @@ class AsyncProcess<CResult> {
try {
incTaskCounters(multiAction.getRegions(), loc.getServerName());
this.pool.submit(runnable);
- } catch (RejectedExecutionException ree) {
- // This should never happen. But as the pool is provided by the end user, let's secure
- // this a little.
+ } catch (Throwable t) {
+ if (t instanceof RejectedExecutionException) {
+ // This should never happen. But as the pool is provided by the end user, let's secure
+ // this a little.
+ LOG.warn("#" + id + ", the task was rejected by the pool. This is unexpected."
+ + " Server is " + loc.getServerName(), t);
+ } else {
+ // see #HBASE-14359 for more details
+ LOG.warn("Caught unexpected exception/error: ", t);
+ }
decTaskCounters(multiAction.getRegions(), loc.getServerName());
- LOG.warn("#" + id + ", the task was rejected by the pool. This is unexpected." +
- " Server is " + loc.getServerName(), ree);
// We're likely to fail again, but this will increment the attempt counter, so it will
// finish.
- receiveGlobalFailure(initialActions, multiAction, loc, numAttempt, ree, errorsByServer);
+ receiveGlobalFailure(initialActions, multiAction, loc, numAttempt, t, errorsByServer);
}
}
}