|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.james.system.hbase.TablePool
public class TablePool
Table Pool singleton to get the DomainList, RecipientRewriteTable and UserRepository HBase tables. TODO Two getInstance methods are public, one for the impl, one for the tests. This is not good.
| Constructor Summary | |
|---|---|
TablePool()
|
|
| Method Summary | |
|---|---|
org.apache.hadoop.hbase.client.HTable |
getDomainlistTable()
Get an instance of the HDomainList table. |
static TablePool |
getInstance()
Use getInstance to get an instance of the HTablePool. |
static TablePool |
getInstance(org.apache.hadoop.conf.Configuration configuration)
Use getInstance to get an instance of the HTablePool. |
org.apache.hadoop.hbase.client.HTable |
getRecipientRewriteTable()
Get an instance of the RecipientRewriteTable table. |
org.apache.hadoop.hbase.client.HTable |
getUsersRepositoryTable()
Get an instance of the UsersRepository table. |
void |
putTable(org.apache.hadoop.hbase.client.HTable table)
Put back the table in the pool after usage. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public TablePool()
| Method Detail |
|---|
public static TablePool getInstance()
throws IOException
HTablePool.
Don't give any configuration, the default one will be used
via HBaseConfiguration.create(Configuration).
If you want to create the instance with a specific HBaseConfiguration,
use getInstance(Configuration)
IOException
public static TablePool getInstance(org.apache.hadoop.conf.Configuration configuration)
throws IOException
HTablePool.
You can give at first call a specific HBaseConfiguration to suit your needs.
configuration -
HTablePool
IOExceptionpublic org.apache.hadoop.hbase.client.HTable getDomainlistTable()
HDomainList table.
HDomainListpublic org.apache.hadoop.hbase.client.HTable getRecipientRewriteTable()
RecipientRewriteTablepublic org.apache.hadoop.hbase.client.HTable getUsersRepositoryTable()
UsersRepositorypublic void putTable(org.apache.hadoop.hbase.client.HTable table)
table -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||