@InterfaceAudience.Private public class OHTableFactory extends Object
All created HTable will share the same thread pool. Also support setting table attributes for the created table. e.g. auto flush, write buffer size.
Setting the table attributes through the method of OHTablePool.
For example, see OHTablePool.setAutoFlush(String, boolean)
| 构造器和说明 |
|---|
OHTableFactory(org.apache.hadoop.conf.Configuration conf,
OHTablePool tablePool) |
OHTableFactory(org.apache.hadoop.conf.Configuration conf,
OHTablePool tablePool,
ExecutorService createTableThreadPool) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
close()
close the factory resources, example create table threadPool
|
org.apache.hadoop.hbase.client.Table |
createHTableInterface(org.apache.hadoop.conf.Configuration config,
byte[] tableName) |
void |
releaseHTableInterface(org.apache.hadoop.hbase.client.Table table) |
public OHTableFactory(org.apache.hadoop.conf.Configuration conf,
OHTablePool tablePool)
public OHTableFactory(org.apache.hadoop.conf.Configuration conf,
OHTablePool tablePool,
ExecutorService createTableThreadPool)
public org.apache.hadoop.hbase.client.Table createHTableInterface(org.apache.hadoop.conf.Configuration config,
byte[] tableName)
public void releaseHTableInterface(org.apache.hadoop.hbase.client.Table table)
throws IOException
IOExceptionpublic void close()
Copyright © 2025. All rights reserved.