Package org.apache.hadoop.hbase.client

Examples of org.apache.hadoop.hbase.client.RetriesExhaustedWithDetailsException


      put.add(Bytes.toBytes("family"), Bytes.toBytes("c1"), new byte[]{'b'});
      ht.put(put);
      ht.close();
    } catch (IOException ioe) {
      Assert.assertTrue(ioe instanceof RetriesExhaustedWithDetailsException);
      RetriesExhaustedWithDetailsException re = (RetriesExhaustedWithDetailsException) ioe;
      boolean foundRegionInRecoveryException = false;
      for (Throwable t : re.getCauses()) {
        if (t instanceof RegionInRecoveryException) {
          foundRegionInRecoveryException = true;
          break;
        }
      }
      Assert.assertTrue(
        "No RegionInRecoveryException. Following exceptions returned=" + re.getCauses(),
        foundRegionInRecoveryException);
    }

    zkw.close();
  }
View Full Code Here


    private void recordFailure(final Mutation m, final long keyBase,
        final long start, IOException e) {
      failedKeySet.add(keyBase);
      String exceptionInfo;
      if (e instanceof RetriesExhaustedWithDetailsException) {
        RetriesExhaustedWithDetailsException aggEx = (RetriesExhaustedWithDetailsException) e;
        exceptionInfo = aggEx.getExhaustiveDescription();
      } else {
        StringWriter stackWriter = new StringWriter();
        PrintWriter pw = new PrintWriter(stackWriter);
        e.printStackTrace(pw);
        pw.flush();
View Full Code Here

      totalOpTimeMs.addAndGet(System.currentTimeMillis() - start);
    } catch (IOException e) {
      failedKeySet.add(keyBase);
      String exceptionInfo;
      if (e instanceof RetriesExhaustedWithDetailsException) {
        RetriesExhaustedWithDetailsException aggEx = (RetriesExhaustedWithDetailsException)e;
        exceptionInfo = aggEx.getExhaustiveDescription();
      } else {
        StringWriter stackWriter = new StringWriter();
        PrintWriter pw = new PrintWriter(stackWriter);
        e.printStackTrace(pw);
        pw.flush();
View Full Code Here

          return;
        }
        failedKeySet.add(keyBase);
        String exceptionInfo;
        if (e instanceof RetriesExhaustedWithDetailsException) {
          RetriesExhaustedWithDetailsException aggEx = (RetriesExhaustedWithDetailsException) e;
          exceptionInfo = aggEx.getExhaustiveDescription();
        } else {
          exceptionInfo = StringUtils.stringifyException(e);
        }
        LOG.error("Failed to mutate: " + keyBase + " after " +
            (System.currentTimeMillis() - start) +
View Full Code Here

      put.add(Bytes.toBytes("family"), Bytes.toBytes("c1"), new byte[]{'b'});
      ht.put(put);
      ht.close();
    } catch (IOException ioe) {
      Assert.assertTrue(ioe instanceof RetriesExhaustedWithDetailsException);
      RetriesExhaustedWithDetailsException re = (RetriesExhaustedWithDetailsException) ioe;
      boolean foundRegionInRecoveryException = false;
      for (Throwable t : re.getCauses()) {
        if (t instanceof RegionInRecoveryException) {
          foundRegionInRecoveryException = true;
          break;
        }
      }
      Assert.assertTrue(
        "No RegionInRecoveryException. Following exceptions returned=" + re.getCauses(),
        foundRegionInRecoveryException);
    }

    zkw.close();
  }
View Full Code Here

      put.add(Bytes.toBytes("family"), Bytes.toBytes("c1"), new byte[]{'b'});
      ht.put(put);
      ht.close();
    } catch (IOException ioe) {
      Assert.assertTrue(ioe instanceof RetriesExhaustedWithDetailsException);
      RetriesExhaustedWithDetailsException re = (RetriesExhaustedWithDetailsException) ioe;
      boolean foundRegionInRecoveryException = false;
      for (Throwable t : re.getCauses()) {
        if (t instanceof RegionInRecoveryException) {
          foundRegionInRecoveryException = true;
          break;
        }
      }
      Assert.assertTrue(
        "No RegionInRecoveryException. Following exceptions returned=" + re.getCauses(),
        foundRegionInRecoveryException);
    }

    zkw.close();
  }
View Full Code Here

      totalOpTimeMs.addAndGet(System.currentTimeMillis() - start);
    } catch (IOException e) {
      failedKeySet.add(keyBase);
      String exceptionInfo;
      if (e instanceof RetriesExhaustedWithDetailsException) {
        RetriesExhaustedWithDetailsException aggEx = (RetriesExhaustedWithDetailsException)e;
        exceptionInfo = aggEx.getExhaustiveDescription();
      } else {
        StringWriter stackWriter = new StringWriter();
        PrintWriter pw = new PrintWriter(stackWriter);
        e.printStackTrace(pw);
        pw.flush();
View Full Code Here

      totalOpTimeMs.addAndGet(System.currentTimeMillis() - start);
    } catch (IOException e) {
      failedKeySet.add(keyBase);
      String exceptionInfo;
      if (e instanceof RetriesExhaustedWithDetailsException) {
        RetriesExhaustedWithDetailsException aggEx = (RetriesExhaustedWithDetailsException)e;
        exceptionInfo = aggEx.getExhaustiveDescription();
      } else {
        StringWriter stackWriter = new StringWriter();
        PrintWriter pw = new PrintWriter(stackWriter);
        e.printStackTrace(pw);
        pw.flush();
View Full Code Here

      totalOpTimeMs.addAndGet(System.currentTimeMillis() - start);
    } catch (IOException e) {
      failedKeySet.add(keyBase);
      String exceptionInfo;
      if (e instanceof RetriesExhaustedWithDetailsException) {
        RetriesExhaustedWithDetailsException aggEx = (RetriesExhaustedWithDetailsException)e;
        exceptionInfo = aggEx.getExhaustiveDescription();
      } else {
        StringWriter stackWriter = new StringWriter();
        PrintWriter pw = new PrintWriter(stackWriter);
        e.printStackTrace(pw);
        pw.flush();
View Full Code Here

      Put put = new Put(key);
      put.add(Bytes.toBytes("family"), Bytes.toBytes("c1"), new byte[]{'b'});
      ht.put(put);
    } catch (IOException ioe) {
      Assert.assertTrue(ioe instanceof RetriesExhaustedWithDetailsException);
      RetriesExhaustedWithDetailsException re = (RetriesExhaustedWithDetailsException) ioe;
      Assert.assertTrue(re.getCause(0) instanceof RegionInRecoveryException);
    }

    ht.close();
    zkw.close();
  }
View Full Code Here

TOP

Related Classes of org.apache.hadoop.hbase.client.RetriesExhaustedWithDetailsException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.