com.google.cloud.bigtable.hbase2_x
Class BigtableAsyncBufferedMutator
- java.lang.Object
-
- com.google.cloud.bigtable.hbase2_x.BigtableAsyncBufferedMutator
-
- All Implemented Interfaces:
- Closeable, AutoCloseable, AsyncBufferedMutator
public class BigtableAsyncBufferedMutator extends Object implements AsyncBufferedMutator
Bigtable implementation ofAsyncBufferedMutator
- Author:
- spollapally
-
-
Constructor Summary
Constructors Constructor and Description BigtableAsyncBufferedMutator(HBaseRequestAdapter adapter, org.apache.hadoop.conf.Configuration configuration, BigtableSession session)
Constructor for BigtableBufferedMutator.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description void
close()
void
flush()
org.apache.hadoop.conf.Configuration
getConfiguration()
TableName
getName()
long
getWriteBufferSize()
List<CompletableFuture<Void>>
mutate(List<? extends Mutation> mutations)
CompletableFuture<Void>
mutate(Mutation mutation)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.hadoop.hbase.client.AsyncBufferedMutator
getPeriodicalFlushTimeout
-
-
-
-
Constructor Detail
-
BigtableAsyncBufferedMutator
public BigtableAsyncBufferedMutator(HBaseRequestAdapter adapter, org.apache.hadoop.conf.Configuration configuration, BigtableSession session)
Constructor for BigtableBufferedMutator.- Parameters:
adapter
- Converts HBase objects to Bigtable protosconfiguration
- For Additional configuration. TODO: move this to optionssession
- aBigtableSession
-
-
Method Detail
-
close
public void close()
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceAsyncBufferedMutator
-
flush
public void flush()
- Specified by:
flush
in interfaceAsyncBufferedMutator
-
getConfiguration
public org.apache.hadoop.conf.Configuration getConfiguration()
- Specified by:
getConfiguration
in interfaceAsyncBufferedMutator
-
getName
public TableName getName()
- Specified by:
getName
in interfaceAsyncBufferedMutator
-
getWriteBufferSize
public long getWriteBufferSize()
- Specified by:
getWriteBufferSize
in interfaceAsyncBufferedMutator
-
mutate
public List<CompletableFuture<Void>> mutate(List<? extends Mutation> mutations)
- Specified by:
mutate
in interfaceAsyncBufferedMutator
-
mutate
public CompletableFuture<Void> mutate(Mutation mutation)
Being a Mutation. This method will block if either of the following are true: 1) There are more than
maxInflightRpcs
RPCs in flight 2) There are more thangetWriteBufferSize()
bytes pending- Specified by:
mutate
in interfaceAsyncBufferedMutator
-
-