Package org.apache.hadoop.hbase.exceptions

Examples of org.apache.hadoop.hbase.exceptions.FailedSanityCheckException


    for (List<Cell> kvs : familyMap.values()) {
      for (Cell cell : kvs) {
        // see if the user-side TS is out of range. latest = server-side
        KeyValue kv = KeyValueUtil.ensureKeyValue(cell);
        if (!kv.isLatestTimestamp() && kv.getTimestamp() > maxTs) {
          throw new FailedSanityCheckException("Timestamp for KV out of range "
              + cell + " (too.new=" + timestampSlop + ")");
        }
      }
    }
  }
View Full Code Here


            e = new NoSuchColumnFamilyException(codes[i].getExceptionMsg());
            builder.addResultOrException(getResultOrException(e, index));
            break;

          case SANITY_CHECK_FAILURE:
            e = new FailedSanityCheckException(codes[i].getExceptionMsg());
            builder.addResultOrException(getResultOrException(e, index));
            break;

          default:
            e = new DoNotRetryIOException(codes[i].getExceptionMsg());
View Full Code Here

    Pair<Mutation, Integer>[] mutateWithLocks = new Pair[] {
      new Pair<Mutation, Integer>(mutation, lid)
    };
    OperationStatus[] batchMutate = this.batchMutate(mutateWithLocks);
    if (batchMutate[0].getOperationStatusCode().equals(OperationStatusCode.SANITY_CHECK_FAILURE)) {
      throw new FailedSanityCheckException(batchMutate[0].getExceptionMsg());
    } else if (batchMutate[0].getOperationStatusCode().equals(OperationStatusCode.BAD_FAMILY)) {
      throw new NoSuchColumnFamilyException(batchMutate[0].getExceptionMsg());
    }
  }
View Full Code Here

    for (List<? extends Cell> kvs : familyMap.values()) {
      for (Cell cell : kvs) {
        // see if the user-side TS is out of range. latest = server-side
        KeyValue kv = KeyValueUtil.ensureKeyValue(cell);
        if (!kv.isLatestTimestamp() && kv.getTimestamp() > maxTs) {
          throw new FailedSanityCheckException("Timestamp for KV out of range "
              + cell + " (too.new=" + timestampSlop + ")");
        }
      }
    }
  }
View Full Code Here

  private void doBatchMutate(Mutation mutation) throws IOException, DoNotRetryIOException {
    // Currently this is only called for puts and deletes, so no nonces.
    OperationStatus[] batchMutate = this.batchMutate(new Mutation[] { mutation },
        HConstants.NO_NONCE, HConstants.NO_NONCE);
    if (batchMutate[0].getOperationStatusCode().equals(OperationStatusCode.SANITY_CHECK_FAILURE)) {
      throw new FailedSanityCheckException(batchMutate[0].getExceptionMsg());
    } else if (batchMutate[0].getOperationStatusCode().equals(OperationStatusCode.BAD_FAMILY)) {
      throw new NoSuchColumnFamilyException(batchMutate[0].getExceptionMsg());
    }
  }
View Full Code Here

    for (List<Cell> kvs : familyMap.values()) {
      for (Cell cell : kvs) {
        // see if the user-side TS is out of range. latest = server-side
        KeyValue kv = KeyValueUtil.ensureKeyValue(cell);
        if (!kv.isLatestTimestamp() && kv.getTimestamp() > maxTs) {
          throw new FailedSanityCheckException("Timestamp for KV out of range "
              + cell + " (too.new=" + timestampSlop + ")");
        }
      }
    }
  }
View Full Code Here

            e = new NoSuchColumnFamilyException(codes[i].getExceptionMsg());
            builder.addResultOrException(getResultOrException(e, index));
            break;

          case SANITY_CHECK_FAILURE:
            e = new FailedSanityCheckException(codes[i].getExceptionMsg());
            builder.addResultOrException(getResultOrException(e, index));
            break;

          default:
            e = new DoNotRetryIOException(codes[i].getExceptionMsg());
View Full Code Here

  private void doBatchMutate(Mutation mutation) throws IOException, DoNotRetryIOException {
    // Currently this is only called for puts and deletes, so no nonces.
    OperationStatus[] batchMutate = this.batchMutate(new Mutation[] { mutation },
        HConstants.NO_NONCE, HConstants.NO_NONCE);
    if (batchMutate[0].getOperationStatusCode().equals(OperationStatusCode.SANITY_CHECK_FAILURE)) {
      throw new FailedSanityCheckException(batchMutate[0].getExceptionMsg());
    } else if (batchMutate[0].getOperationStatusCode().equals(OperationStatusCode.BAD_FAMILY)) {
      throw new NoSuchColumnFamilyException(batchMutate[0].getExceptionMsg());
    }
  }
View Full Code Here

    for (List<Cell> kvs : familyMap.values()) {
      for (Cell cell : kvs) {
        // see if the user-side TS is out of range. latest = server-side
        KeyValue kv = KeyValueUtil.ensureKeyValue(cell);
        if (!kv.isLatestTimestamp() && kv.getTimestamp() > maxTs) {
          throw new FailedSanityCheckException("Timestamp for KV out of range "
              + cell + " (too.new=" + timestampSlop + ")");
        }
      }
    }
  }
View Full Code Here

  @Override
  public Result preAppend(ObserverContext<RegionCoprocessorEnvironment> e, Append append)
      throws IOException {
    for (CellScanner cellScanner = append.cellScanner(); cellScanner.advance();) {
      if (!checkForReservedVisibilityTagPresence(cellScanner.current())) {
        throw new FailedSanityCheckException("Append contains cell with reserved type tag");
      }
    }
    return null;
  }
View Full Code Here

TOP

Related Classes of org.apache.hadoop.hbase.exceptions.FailedSanityCheckException

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.