org.apache.accumulo.core.metadata
Class MetadataServicer

java.lang.Object
  extended by org.apache.accumulo.core.metadata.MetadataServicer

public abstract class MetadataServicer
extends Object

Provides a consolidated API for handling table metadata


Constructor Summary
MetadataServicer()
           
 
Method Summary
static MetadataServicer forTableId(Instance instance, Credentials credentials, String tableId)
           
static MetadataServicer forTableName(Instance instance, Credentials credentials, String tableName)
           
abstract  String getServicedTableId()
           
abstract  void getTabletLocations(SortedMap<KeyExtent,String> tablets)
          Populate the provided data structure with the known tablets for the table being serviced
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MetadataServicer

public MetadataServicer()
Method Detail

forTableName

public static MetadataServicer forTableName(Instance instance,
                                            Credentials credentials,
                                            String tableName)
                                     throws AccumuloException,
                                            AccumuloSecurityException
Throws:
AccumuloException
AccumuloSecurityException

forTableId

public static MetadataServicer forTableId(Instance instance,
                                          Credentials credentials,
                                          String tableId)

getServicedTableId

public abstract String getServicedTableId()
Returns:
the table id of the table currently being serviced

getTabletLocations

public abstract void getTabletLocations(SortedMap<KeyExtent,String> tablets)
                                 throws AccumuloException,
                                        AccumuloSecurityException,
                                        TableNotFoundException
Populate the provided data structure with the known tablets for the table being serviced

Parameters:
tablets - A mapping of all known tablets to their location (if available, null otherwise)
Throws:
AccumuloException
AccumuloSecurityException
TableNotFoundException


Copyright © 2015 Apache Accumulo Project. All rights reserved.