Java 类org.apache.hadoop.hbase.client.BufferedMutator.ExceptionListener 实例源码

项目:stroom-stats    文件:HBaseTable.java   
public BufferedMutator getBufferedMutator(final ExceptionListener exceptionListener) {
    final BufferedMutatorParams params = new BufferedMutatorParams(getName()).listener(exceptionListener);

    BufferedMutator bufferedMutator;
    try {
        bufferedMutator = hBaseConnection.getConnection().getBufferedMutator(params);
    } catch (final Exception e) {
        throw new HBaseException("Unable to create buffered mutator for table " + getDisplayName(), e);
    }

    return bufferedMutator;
}
项目:cloud-bigtable-client    文件:TestBigtableBufferedMutator.java   
private void setup() {
  setup(new BufferedMutator.ExceptionListener() {
    @Override
    public void onException(RetriesExhaustedWithDetailsException exception,
        BufferedMutator mutator) throws RetriesExhaustedWithDetailsException {
      throw exception;
    }
  });
}
项目:cloud-bigtable-client    文件:TestBigtableBufferedMutator.java   
private void setup(ExceptionListener listener) {
  underTest = new BigtableBufferedMutator(executor,
      BigtableConnection.BIGTABLE_BUFFERED_MUTATOR_MAX_MEMORY_DEFAULT,
      listener,
      null,
      BigtableConnection.MAX_INFLIGHT_RPCS_DEFAULT,
      TableName.valueOf("TABLE"));
}