@InterfaceAudience.Private public class TableNamespaceManager extends Object
ZKNamespaceManager
Modifier and Type | Field and Description |
---|---|
private org.apache.hadoop.conf.Configuration |
conf |
(package private) static int |
DEFAULT_NS_INIT_TIMEOUT |
private boolean |
initialized |
static String |
KEY_MAX_REGIONS |
static String |
KEY_MAX_TABLES |
private static org.apache.commons.logging.Log |
LOG |
private MasterServices |
masterServices |
(package private) static String |
NS_INIT_TIMEOUT |
private Table |
nsTable |
private ZKNamespaceManager |
zkNamespaceManager |
Constructor and Description |
---|
TableNamespaceManager(MasterServices masterServices) |
Modifier and Type | Method and Description |
---|---|
void |
create(NamespaceDescriptor ns) |
private void |
create(Table table,
NamespaceDescriptor ns) |
private void |
createNamespaceTable(MasterServices masterServices) |
NamespaceDescriptor |
get(String name) |
private NamespaceDescriptor |
get(Table table,
String name) |
static long |
getMaxRegions(NamespaceDescriptor ns) |
static long |
getMaxTables(NamespaceDescriptor ns) |
private Table |
getNamespaceTable() |
private boolean |
isTableAssigned() |
boolean |
isTableAvailableAndInitialized()
This method checks if the namespace table is assigned and then
tries to create its HTable.
|
NavigableSet<NamespaceDescriptor> |
list() |
void |
remove(String name) |
void |
start() |
void |
update(NamespaceDescriptor ns) |
private void |
upsert(Table table,
NamespaceDescriptor ns) |
(package private) void |
validateTableAndRegionCount(NamespaceDescriptor desc) |
private static final org.apache.commons.logging.Log LOG
private org.apache.hadoop.conf.Configuration conf
private MasterServices masterServices
private Table nsTable
private ZKNamespaceManager zkNamespaceManager
private boolean initialized
public static final String KEY_MAX_REGIONS
public static final String KEY_MAX_TABLES
static final String NS_INIT_TIMEOUT
static final int DEFAULT_NS_INIT_TIMEOUT
public TableNamespaceManager(MasterServices masterServices)
public void start() throws IOException
IOException
private Table getNamespaceTable() throws IOException
IOException
public NamespaceDescriptor get(String name) throws IOException
IOException
public void create(NamespaceDescriptor ns) throws IOException
IOException
public void update(NamespaceDescriptor ns) throws IOException
IOException
private NamespaceDescriptor get(Table table, String name) throws IOException
IOException
private void create(Table table, NamespaceDescriptor ns) throws IOException
IOException
private void upsert(Table table, NamespaceDescriptor ns) throws IOException
IOException
public void remove(String name) throws IOException
IOException
public NavigableSet<NamespaceDescriptor> list() throws IOException
IOException
private void createNamespaceTable(MasterServices masterServices) throws IOException
IOException
public boolean isTableAvailableAndInitialized() throws IOException
IOException
private boolean isTableAssigned()
void validateTableAndRegionCount(NamespaceDescriptor desc) throws IOException
IOException
public static long getMaxTables(NamespaceDescriptor ns) throws IOException
IOException
public static long getMaxRegions(NamespaceDescriptor ns) throws IOException
IOException
Copyright © 2007–2019 The Apache Software Foundation. All rights reserved.