Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
 
 package org.apache.hadoop.hbase.master;
 
 import java.util.List;
 
 
Services Master supplies
 
 public interface MasterServices extends Server {
  

Returns:
Master's instance of the AssignmentManager
 

Returns:
Master's filesystem MasterFileSystem utility class.
 

Returns:
Master's ServerManager instance.
 
 

Returns:
Master's instance of TableLockManager
 

Returns:
Master's instance of MasterCoprocessorHost
 
Check table is modifiable; i.e. exists and is offline.

 
   // We actually throw the exceptions mentioned in the
   void checkTableModifiable(final TableName tableName)
Create a table using the given table definition.

Parameters:
desc The table definition
splitKeys Starting row keys for the initial table regions. If null a single region is created.
 
   void createTable(HTableDescriptor descbyte[][] splitKeys)
       throws IOException;

  
Delete a table

Parameters:
tableName The table name
Throws:
java.io.IOException
 
   void deleteTable(final TableName tableNamethrows IOException;

  
Truncate a table

Parameters:
tableName The table name
preserveSplits True if the splits should be preserved
Throws:
java.io.IOException
  public void truncateTable(final TableName tableNameboolean preserveSplitsthrows IOException;

  
Modify the descriptor of an existing table

Parameters:
tableName The table name
descriptor The updated table descriptor
Throws:
java.io.IOException
  void modifyTable(final TableName tableNamefinal HTableDescriptor descriptor)
      throws IOException;

  
Enable an existing table

Parameters:
tableName The table name
Throws:
java.io.IOException
  void enableTable(final TableName tableNamethrows IOException;

  
Disable an existing table

Parameters:
tableName The table name
Throws:
java.io.IOException
  void disableTable(final TableName tableNamethrows IOException;


  
Add a new column to an existing table

Parameters:
tableName The table name
column The column definition
Throws:
java.io.IOException
  void addColumn(final TableName tableNamefinal HColumnDescriptor column)
      throws IOException;

  
Modify the column descriptor of an existing column in an existing table

Parameters:
tableName The table name
descriptor The updated column definition
Throws:
java.io.IOException
  void modifyColumn(TableName tableNameHColumnDescriptor descriptor)
      throws IOException;

  
Delete a column from an existing table

Parameters:
tableName The table name
columnName The column name
Throws:
java.io.IOException
  void deleteColumn(final TableName tableNamefinal byte[] columnName)
      throws IOException;

  

Returns:
Return table descriptors implementation.

Returns:
true if master enables ServerShutdownHandler;
Registers a new protocol buffer com.google.protobuf.Service subclass as a master coprocessor endpoint.

Only a single instance may be registered for a given com.google.protobuf.Service subclass (the instances are keyed on com.google.protobuf.Descriptors.ServiceDescriptor.getFullName(). After the first registration, subsequent calls with the same service name will fail with a return value of false.

Parameters:
instance the Service subclass instance to expose as a coprocessor endpoint
Returns:
true if the registration was successful, false otherwise
  boolean registerService(Service instance);

  
Merge two regions. The real implementation is on the regionserver, master just move the regions together and send MERGE RPC to regionserver

Parameters:
region_a region to merge
region_b region to merge
forcible true if do a compulsory merge, otherwise we will only merge two adjacent regions
Throws:
java.io.IOException
    final HRegionInfo region_afinal HRegionInfo region_bfinal boolean forcible
  ) throws IOException;

  

Returns:
true if master is initialized
  boolean isInitialized();

  
Create a new namespace

Parameters:
descriptor descriptor which describes the new namespace
Throws:
java.io.IOException
  public void createNamespace(NamespaceDescriptor descriptorthrows IOException;

  
Modify an existing namespace

Parameters:
descriptor descriptor which updates the existing namespace
Throws:
java.io.IOException
  public void modifyNamespace(NamespaceDescriptor descriptorthrows IOException;

  
Delete an existing namespace. Only empty namespaces (no tables) can be removed.

Parameters:
name namespace name
Throws:
java.io.IOException
  public void deleteNamespace(String namethrows IOException;

  
Get a namespace descriptor by name

Parameters:
name name of namespace descriptor
Returns:
A descriptor
Throws:
java.io.IOException
List available namespace descriptors

Returns:
A descriptor
Throws:
java.io.IOException
Get list of table descriptors by namespace

Parameters:
name namespace name
Returns:
descriptors
Throws:
java.io.IOException
Get list of table names by namespace

Parameters:
name namespace name
Returns:
table names
Throws:
java.io.IOException
New to GrepCode? Check out our FAQ X