Java Code Examples for org.apache.hadoop.hbase.client.OperationWithAttributes#getAttribute()

The following examples show how to use org.apache.hadoop.hbase.client.OperationWithAttributes#getAttribute() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 5 votes vote down vote up
private Transaction getFromOperation(OperationWithAttributes op) throws IOException {
  byte[] encoded = op.getAttribute(TxConstants.TX_OPERATION_ATTRIBUTE_KEY);
  if (encoded == null) {
    // to support old clients
    encoded = op.getAttribute(TxConstants.OLD_TX_OPERATION_ATTRIBUTE_KEY);
  }
  if (encoded != null) {
    return txCodec.decode(encoded);
  }
  return null;
}
 
Example 2
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 5 votes vote down vote up
private Transaction getFromOperation(OperationWithAttributes op) throws IOException {
  byte[] encoded = op.getAttribute(TxConstants.TX_OPERATION_ATTRIBUTE_KEY);
  if (encoded == null) {
    // to support old clients
    encoded = op.getAttribute(TxConstants.OLD_TX_OPERATION_ATTRIBUTE_KEY);
  }
  if (encoded != null) {
    return txCodec.decode(encoded);
  }
  return null;
}
 
Example 3
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 5 votes vote down vote up
private Transaction getFromOperation(OperationWithAttributes op) throws IOException {
  byte[] encoded = op.getAttribute(TxConstants.TX_OPERATION_ATTRIBUTE_KEY);
  if (encoded == null) {
    // to support old clients
    encoded = op.getAttribute(TxConstants.OLD_TX_OPERATION_ATTRIBUTE_KEY);
  }
  if (encoded != null) {
    return txCodec.decode(encoded);
  }
  return null;
}
 
Example 4
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 5 votes vote down vote up
private Transaction getFromOperation(OperationWithAttributes op) throws IOException {
  byte[] encoded = op.getAttribute(TxConstants.TX_OPERATION_ATTRIBUTE_KEY);
  if (encoded == null) {
    // to support old clients
    encoded = op.getAttribute(TxConstants.OLD_TX_OPERATION_ATTRIBUTE_KEY);
  }
  if (encoded != null) {
    return txCodec.decode(encoded);
  }
  return null;
}
 
Example 5
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 5 votes vote down vote up
private Transaction getFromOperation(OperationWithAttributes op) throws IOException {
  byte[] encoded = op.getAttribute(TxConstants.TX_OPERATION_ATTRIBUTE_KEY);
  if (encoded == null) {
    // to support old clients
    encoded = op.getAttribute(TxConstants.OLD_TX_OPERATION_ATTRIBUTE_KEY);
  }
  if (encoded != null) {
    return txCodec.decode(encoded);
  }
  return null;
}
 
Example 6
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 5 votes vote down vote up
private Transaction getFromOperation(OperationWithAttributes op) throws IOException {
  byte[] encoded = op.getAttribute(TxConstants.TX_OPERATION_ATTRIBUTE_KEY);
  if (encoded == null) {
    // to support old clients
    encoded = op.getAttribute(TxConstants.OLD_TX_OPERATION_ATTRIBUTE_KEY);
  }
  if (encoded != null) {
    return txCodec.decode(encoded);
  }
  return null;
}
 
Example 7
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 5 votes vote down vote up
private Transaction getFromOperation(OperationWithAttributes op) throws IOException {
  byte[] encoded = op.getAttribute(TxConstants.TX_OPERATION_ATTRIBUTE_KEY);
  if (encoded == null) {
    // to support old clients
    encoded = op.getAttribute(TxConstants.OLD_TX_OPERATION_ATTRIBUTE_KEY);
  }
  if (encoded != null) {
    return txCodec.decode(encoded);
  }
  return null;
}
 
Example 8
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 5 votes vote down vote up
private Transaction getFromOperation(OperationWithAttributes op) throws IOException {
  byte[] encoded = op.getAttribute(TxConstants.TX_OPERATION_ATTRIBUTE_KEY);
  if (encoded == null) {
    // to support old clients
    encoded = op.getAttribute(TxConstants.OLD_TX_OPERATION_ATTRIBUTE_KEY);
  }
  if (encoded != null) {
    return txCodec.decode(encoded);
  }
  return null;
}
 
Example 9
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 4 votes vote down vote up
private boolean isRollbackOperation(OperationWithAttributes op) throws IOException {
  return op.getAttribute(TxConstants.TX_ROLLBACK_ATTRIBUTE_KEY) != null ||
    // to support old clients
    op.getAttribute(TxConstants.OLD_TX_ROLLBACK_ATTRIBUTE_KEY) != null;
}
 
Example 10
Source File: SIObserver.java    From spliceengine with GNU Affero General Public License v3.0 4 votes vote down vote up
protected EntryPredicateFilter getPredicateFilter(OperationWithAttributes operation) throws IOException{
    final byte[] serializedPredicateFilter=operation.getAttribute(ENTRY_PREDICATE_LABEL);
    return EntryPredicateFilter.fromBytes(serializedPredicateFilter);
}
 
Example 11
Source File: SIObserver.java    From spliceengine with GNU Affero General Public License v3.0 4 votes vote down vote up
protected boolean shouldUseSI(OperationWithAttributes op){
    if(op.getAttribute(SIConstants.SI_NEEDED)==null) return false;
    else return op.getAttribute(SIConstants.SUPPRESS_INDEXING_ATTRIBUTE_NAME)==null;
}
 
Example 12
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 4 votes vote down vote up
private boolean isRollbackOperation(OperationWithAttributes op) throws IOException {
  return op.getAttribute(TxConstants.TX_ROLLBACK_ATTRIBUTE_KEY) != null ||
    // to support old clients
    op.getAttribute(TxConstants.OLD_TX_ROLLBACK_ATTRIBUTE_KEY) != null;
}
 
Example 13
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 4 votes vote down vote up
private boolean isRollbackOperation(OperationWithAttributes op) throws IOException {
  return op.getAttribute(TxConstants.TX_ROLLBACK_ATTRIBUTE_KEY) != null ||
    // to support old clients
    op.getAttribute(TxConstants.OLD_TX_ROLLBACK_ATTRIBUTE_KEY) != null;
}
 
Example 14
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 4 votes vote down vote up
private boolean isRollbackOperation(OperationWithAttributes op) throws IOException {
  return op.getAttribute(TxConstants.TX_ROLLBACK_ATTRIBUTE_KEY) != null ||
    // to support old clients
    op.getAttribute(TxConstants.OLD_TX_ROLLBACK_ATTRIBUTE_KEY) != null;
}
 
Example 15
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 4 votes vote down vote up
private boolean isRollbackOperation(OperationWithAttributes op) throws IOException {
  return op.getAttribute(TxConstants.TX_ROLLBACK_ATTRIBUTE_KEY) != null ||
  // to support old clients
      op.getAttribute(TxConstants.OLD_TX_ROLLBACK_ATTRIBUTE_KEY) != null;
}
 
Example 16
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 4 votes vote down vote up
private boolean isRollbackOperation(OperationWithAttributes op) throws IOException {
  return op.getAttribute(TxConstants.TX_ROLLBACK_ATTRIBUTE_KEY) != null ||
    // to support old clients
    op.getAttribute(TxConstants.OLD_TX_ROLLBACK_ATTRIBUTE_KEY) != null;
}
 
Example 17
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 4 votes vote down vote up
private boolean isRollbackOperation(OperationWithAttributes op) throws IOException {
  return op.getAttribute(TxConstants.TX_ROLLBACK_ATTRIBUTE_KEY) != null ||
    // to support old clients
    op.getAttribute(TxConstants.OLD_TX_ROLLBACK_ATTRIBUTE_KEY) != null;
}
 
Example 18
Source File: TransactionProcessor.java    From phoenix-tephra with Apache License 2.0 4 votes vote down vote up
private boolean isRollbackOperation(OperationWithAttributes op) throws IOException {
  return op.getAttribute(TxConstants.TX_ROLLBACK_ATTRIBUTE_KEY) != null ||
    // to support old clients
    op.getAttribute(TxConstants.OLD_TX_ROLLBACK_ATTRIBUTE_KEY) != null;
}