org.apache.hadoop.hbase.master
Class TableNamespaceManager

java.lang.Object
  extended by org.apache.hadoop.hbase.master.TableNamespaceManager

@InterfaceAudience.Private
public class TableNamespaceManager
extends Object

This is a helper class used to manage the namespace metadata that is stored in TableName.NAMESPACE_TABLE_NAME It also mirrors updates to the ZK store by forwarding updates to ZKNamespaceManager


Constructor Summary
TableNamespaceManager(MasterServices masterServices)
           
 
Method Summary
 void create(NamespaceDescriptor ns)
           
 NamespaceDescriptor get(String name)
           
 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)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TableNamespaceManager

public TableNamespaceManager(MasterServices masterServices)
Method Detail

start

public void start()
           throws IOException
Throws:
IOException

get

public NamespaceDescriptor get(String name)
                        throws IOException
Throws:
IOException

create

public void create(NamespaceDescriptor ns)
            throws IOException
Throws:
IOException

update

public void update(NamespaceDescriptor ns)
            throws IOException
Throws:
IOException

remove

public void remove(String name)
            throws IOException
Throws:
IOException

list

public NavigableSet<NamespaceDescriptor> list()
                                       throws IOException
Throws:
IOException

isTableAvailableAndInitialized

public boolean isTableAvailableAndInitialized()
                                       throws IOException
This method checks if the namespace table is assigned and then tries to create its HTable. If it was already created before, it also makes sure that the connection isn't closed.

Returns:
true if the namespace table manager is ready to serve, false otherwise
Throws:
IOException


Copyright © 2015 The Apache Software Foundation. All rights reserved.