public class TTable extends Object implements Closeable
Transaction object. It mimics the behavior in Table| Constructor and Description |
|---|
TTable(org.apache.hadoop.hbase.client.Connection connection,
byte[] tableName) |
TTable(org.apache.hadoop.hbase.client.Connection connection,
byte[] tableName,
boolean conflictFree) |
TTable(org.apache.hadoop.hbase.client.Connection connection,
byte[] tableName,
org.apache.omid.committable.CommitTable.Client commitTableClient) |
TTable(org.apache.hadoop.hbase.client.Connection connection,
byte[] tableName,
org.apache.omid.committable.CommitTable.Client commitTableClient,
boolean conflictFree) |
TTable(org.apache.hadoop.hbase.client.Connection connection,
String tableName) |
TTable(org.apache.hadoop.hbase.client.Connection connection,
String tableName,
boolean conflictFree) |
TTable(org.apache.hadoop.hbase.client.Connection connection,
String tableName,
org.apache.omid.committable.CommitTable.Client commitTableClient) |
TTable(org.apache.hadoop.hbase.client.Connection connection,
String tableName,
org.apache.omid.committable.CommitTable.Client commitTableClient,
boolean conflictFree) |
TTable(org.apache.hadoop.hbase.client.Table hTable) |
TTable(org.apache.hadoop.hbase.client.Table hTable,
boolean conflictFree) |
TTable(org.apache.hadoop.hbase.client.Table hTable,
boolean serverSideFilter,
boolean conflictFree) |
TTable(org.apache.hadoop.hbase.client.Table hTable,
org.apache.omid.committable.CommitTable.Client commitTableClient) |
TTable(org.apache.hadoop.hbase.client.Table hTable,
org.apache.omid.committable.CommitTable.Client commitTableClient,
boolean conflictFree) |
TTable(org.apache.hadoop.hbase.client.Table hTable,
SnapshotFilter snapshotFilter) |
TTable(org.apache.hadoop.hbase.client.Table hTable,
SnapshotFilter snapshotFilter,
boolean conflictFree) |
| Modifier and Type | Method and Description |
|---|---|
void |
batch(Transaction transaction,
List<? extends org.apache.hadoop.hbase.client.Row> rows) |
void |
batch(Transaction transaction,
List<? extends org.apache.hadoop.hbase.client.Row> rows,
boolean addShadowCells)
Transactional version of Table#batch(List rows)
|
void |
close()
Releases any resources held or pending changes in internal buffers.
|
void |
delete(Transaction tx,
org.apache.hadoop.hbase.client.Delete delete)
Transactional version of
Table.delete(Delete delete) |
void |
delete(Transaction transaction,
List<org.apache.hadoop.hbase.client.Delete> deletes)
Transactional version of
Table.delete(List deletes) |
boolean |
exists(Transaction transaction,
org.apache.hadoop.hbase.client.Get get)
Transactional version of
Table.exists(Get get) |
void |
flushCommits() |
org.apache.hadoop.hbase.client.Result |
get(Transaction tx,
org.apache.hadoop.hbase.client.Get get)
Transactional version of
Table.get(Get get) |
org.apache.hadoop.hbase.client.Result[] |
get(Transaction transaction,
List<org.apache.hadoop.hbase.client.Get> gets)
Transactional version of
Table.get(List gets) |
org.apache.hadoop.conf.Configuration |
getConfiguration()
Delegates to
Table.getConfiguration() |
org.apache.hadoop.hbase.client.TableDescriptor |
getDescriptor()
Delegates to
Table.getDescriptor() |
org.apache.hadoop.hbase.client.Table |
getHBaseTable()
Return the raw HBase table
This is needed to resolve API incompatibilities between HBase 2 and 3 in Phoenix.
|
org.apache.hadoop.hbase.client.Table |
getHTable()
Provides access to the underliying Table in order to configure it or to perform unsafe (non-transactional)
operations.
|
org.apache.hadoop.hbase.client.ResultScanner |
getScanner(Transaction transaction,
byte[] family)
Transactional version of
Table.getScanner(byte[] family) |
org.apache.hadoop.hbase.client.ResultScanner |
getScanner(Transaction transaction,
byte[] family,
byte[] qualifier)
Transactional version of
Table.getScanner(byte[] family, byte[] qualifier) |
org.apache.hadoop.hbase.client.ResultScanner |
getScanner(Transaction tx,
org.apache.hadoop.hbase.client.Scan scan)
Transactional version of
Table.getScanner(Scan scan) |
org.apache.hadoop.hbase.HTableDescriptor |
getTableDescriptor()
Delegates to
Table.getTableDescriptor()
This deprecated method is implemented for backwards compatibility reasons. |
byte[] |
getTableName() |
boolean |
isAutoFlush() |
static org.apache.hadoop.hbase.client.Put |
markPutAsCommitted(org.apache.hadoop.hbase.client.Put put,
long timestamp,
long commitTimestamp) |
void |
put(Transaction transaction,
List<org.apache.hadoop.hbase.client.Put> puts) |
void |
put(Transaction transaction,
List<org.apache.hadoop.hbase.client.Put> puts,
boolean addShadowCells)
Transactional version of
Table.put(List puts) |
void |
put(Transaction tx,
org.apache.hadoop.hbase.client.Put put)
Transactional version of
Table.put(Put put) |
void |
put(Transaction tx,
org.apache.hadoop.hbase.client.Put put,
boolean addShadowCell) |
void |
setAutoFlush(boolean autoFlush) |
public TTable(org.apache.hadoop.hbase.client.Connection connection,
byte[] tableName)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Connection connection,
byte[] tableName,
org.apache.omid.committable.CommitTable.Client commitTableClient)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Connection connection,
String tableName)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Connection connection,
String tableName,
org.apache.omid.committable.CommitTable.Client commitTableClient)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Table hTable)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Connection connection,
byte[] tableName,
boolean conflictFree)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Connection connection,
byte[] tableName,
org.apache.omid.committable.CommitTable.Client commitTableClient,
boolean conflictFree)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Connection connection,
String tableName,
boolean conflictFree)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Connection connection,
String tableName,
org.apache.omid.committable.CommitTable.Client commitTableClient,
boolean conflictFree)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Table hTable,
boolean conflictFree)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Table hTable,
SnapshotFilter snapshotFilter)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Table hTable,
org.apache.omid.committable.CommitTable.Client commitTableClient)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Table hTable,
boolean serverSideFilter,
boolean conflictFree)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Table hTable,
SnapshotFilter snapshotFilter,
boolean conflictFree)
throws IOException
IOExceptionpublic TTable(org.apache.hadoop.hbase.client.Table hTable,
org.apache.omid.committable.CommitTable.Client commitTableClient,
boolean conflictFree)
throws IOException
IOExceptionpublic void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableIOException - if a remote or network exception occurs.public org.apache.hadoop.hbase.client.Result get(Transaction tx, org.apache.hadoop.hbase.client.Get get) throws IOException
Table.get(Get get)get - an instance of Gettx - an instance of transaction to be usedIOException - if a remote or network exception occurs.public void delete(Transaction tx, org.apache.hadoop.hbase.client.Delete delete) throws IOException
Table.delete(Delete delete)delete - an instance of Deletetx - an instance of transaction to be usedIOException - if a remote or network exception occurs.public void put(Transaction tx, org.apache.hadoop.hbase.client.Put put) throws IOException
Table.put(Put put)put - an instance of Puttx - an instance of transaction to be usedIOException - if a remote or network exception occurs.public static org.apache.hadoop.hbase.client.Put markPutAsCommitted(org.apache.hadoop.hbase.client.Put put,
long timestamp,
long commitTimestamp)
put - an instance of Puttimestamp - timestamp to be used as cells versioncommitTimestamp - timestamp to be used as commit timestamppublic void put(Transaction tx, org.apache.hadoop.hbase.client.Put put, boolean addShadowCell) throws IOException
put - an instance of Puttx - an instance of transaction to be usedaddShadowCell - denotes whether to add the shadow cellIOException - if a remote or network exception occurs.public org.apache.hadoop.hbase.client.ResultScanner getScanner(Transaction tx, org.apache.hadoop.hbase.client.Scan scan) throws IOException
Table.getScanner(Scan scan)scan - an instance of Scantx - an instance of transaction to be usedIOException - if a remote or network exception occurs.public org.apache.hadoop.hbase.client.Table getHBaseTable()
public byte[] getTableName()
public org.apache.hadoop.conf.Configuration getConfiguration()
Table.getConfiguration()public org.apache.hadoop.hbase.HTableDescriptor getTableDescriptor()
throws IOException
Table.getTableDescriptor()
This deprecated method is implemented for backwards compatibility reasons.
use getDescriptor()IOException - if a remote or network exception occurs.public org.apache.hadoop.hbase.client.TableDescriptor getDescriptor()
throws IOException
Table.getDescriptor()IOException - if a remote or network exception occurs.public boolean exists(Transaction transaction, org.apache.hadoop.hbase.client.Get get) throws IOException
Table.exists(Get get)transaction - an instance of transaction to be usedget - an instance of GetIOException - if a remote or network exception occurs.public org.apache.hadoop.hbase.client.Result[] get(Transaction transaction, List<org.apache.hadoop.hbase.client.Get> gets) throws IOException
Table.get(List gets)transaction - an instance of transaction to be usedgets - list of Get instancesIOException - if a remote or network exception occurspublic org.apache.hadoop.hbase.client.ResultScanner getScanner(Transaction transaction, byte[] family) throws IOException
Table.getScanner(byte[] family)transaction - an instance of transaction to be usedfamily - column familyIOException - if a remote or network exception occurspublic org.apache.hadoop.hbase.client.ResultScanner getScanner(Transaction transaction, byte[] family, byte[] qualifier) throws IOException
Table.getScanner(byte[] family, byte[] qualifier)transaction - an instance of transaction to be usedfamily - column familyqualifier - column nameIOException - if a remote or network exception occurspublic void put(Transaction transaction, List<org.apache.hadoop.hbase.client.Put> puts, boolean addShadowCells) throws IOException
Table.put(List puts)transaction - an instance of transaction to be usedputs - List of putsaddShadowCells - denotes whether to add the shadow cellIOException - if a remote or network exception occurspublic void put(Transaction transaction, List<org.apache.hadoop.hbase.client.Put> puts) throws IOException
IOExceptionpublic void batch(Transaction transaction, List<? extends org.apache.hadoop.hbase.client.Row> rows, boolean addShadowCells) throws IOException
transaction - an instance of transaction to be usedrows - List of rows that must be instances of Put or DeleteaddShadowCells - denotes whether to add the shadow cellIOException - if a remote or network exception occurspublic void batch(Transaction transaction, List<? extends org.apache.hadoop.hbase.client.Row> rows) throws IOException
IOExceptionpublic void delete(Transaction transaction, List<org.apache.hadoop.hbase.client.Delete> deletes) throws IOException
Table.delete(List deletes)transaction - an instance of transaction to be useddeletes - List of deletesIOException - if a remote or network exception occurspublic org.apache.hadoop.hbase.client.Table getHTable()
public void setAutoFlush(boolean autoFlush)
throws IOException
IOExceptionpublic boolean isAutoFlush()
public void flushCommits()
throws IOException
IOExceptionCopyright © 2011–2023 Apache Software Foundation. All rights reserved.