accumulo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From joshelser <>
Subject [GitHub] accumulo pull request #243: ACCUMULO-4619 fix split hanging on Error
Date Wed, 05 Apr 2017 19:29:31 GMT
Github user joshelser commented on a diff in the pull request:
    --- Diff: core/src/main/java/org/apache/accumulo/core/client/impl/
    @@ -389,14 +389,17 @@ public void addSplits(String tableName, SortedSet<Text> partitionKeys)
throws Ta
             if (exception.get() != null) {
               Throwable excep = exception.get();
    -          if (excep instanceof TableNotFoundException)
    -            throw (TableNotFoundException) excep;
    -          else if (excep instanceof AccumuloException)
    -            throw (AccumuloException) excep;
    -          else if (excep instanceof AccumuloSecurityException)
    -            throw (AccumuloSecurityException) excep;
    +          if (excep instanceof TableNotFoundException) {
    +            TableNotFoundException tnfe = (TableNotFoundException) excep;
    +            throw new TableNotFoundException(tableId, tableName, "Table not found by
background thread", tnfe);
    +          } else if (excep instanceof AccumuloSecurityException) {
    +            // base == background accumulo security exception
    +            AccumuloSecurityException base = (AccumuloSecurityException) excep;
    +            throw new AccumuloSecurityException(base.getUser(), base.asThriftException().getCode(),
base.getTableInfo(), excep);
    +          } else if (excep instanceof Error)
    +            throw new Error(excep);
    --- End diff --
    I am not yet groking the entirety of this scenario, but trust you know what you're describing.
Can you leave a comment that it is intentional that the Error is re-wrapped?

If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at or file a JIRA ticket
with INFRA.

View raw message