com.nhncorp.neptune.client
Class NTableManager

java.lang.Object
  extended by com.nhncorp.neptune.client.NTableManager
All Implemented Interfaces:
Constants

public class NTableManager
extends java.lang.Object
implements Constants

테이블을 생성하거나 스키마의 변경, drop 등과 같은 DDL(data definit ion language)과 관련된 작업을 수행한다.

Author:
nhn

Field Summary
 
Fields inherited from interface com.nhncorp.neptune.common.Constants
BATCH_RECEIVER_SUCCESS, BATCH_UPLOAD, CHANGELOG_SERVER, COMPACTION, DELETEED, END_RECEIVE_ROW, GROUPS, INDEX_INTERVAL_LENGH, INSERTED, LOG_OP_ADD_COLUMN_VALUE, LOG_OP_CREATE_ROW, LOG_OP_DELETE_COLUMN_VALUE, LOG_OP_MODIFY_META, MAP_RECORD_COLUMN, MAP_RECORD_ROW, MASTER, MASTER_SERVER, MAX_KEY_LENGTH, MAX_VALUE, META_COLUMN_NAME_TABLETINFO, MIN_VALUE, NEPTUNE, OPEN_SCANNER, PATH_SCHEMA, PIPE_CL_FILE_NAME, PROCESS, ROOT_TABLET, SCANNER_END, SCANNER_OPEN_FAIL, SCANNER_OPEN_SUCCESS, SCHEMA_DESCRIPTION_FILE_NAME, SCHEMA_INFO_FILENAME, SERVER, SPLIT, SPLIT_INFO, SPLIT_STORE, SUPERGROUP, TABLE_DROP, TABLE_LOCK, TABLE_NAME_META, TABLE_NAME_ROOT, TABLET_ALIVE, TABLET_ASSIGN, TABLET_AVAIL, TABLET_CREATED, TABLET_DROP, TABLET_FAIL, TABLET_STOP_MARK, TABLETSERVER_SPLIT, TEST_MODE, UPLOAD_END, UPLOAD_FAIL, UPLOAD_START_ROW, UPLOADER, USERS
 
Constructor Summary
NTableManager()
           
 
Method Summary
static void clear()
           
static DataServiceProtocol connectTabletServer(java.lang.String hostName, NConfiguration conf)
           
static DataServiceProtocol connectTabletServer(TabletInfo tabletInfo, NConfiguration conf)
           
static void dropTable(NConfiguration conf, java.lang.String tableName)
          테이블을 drop한다.
static com.nhncorp.pleiades.client.LockService getLockService(NConfiguration conf)
           
static TableManagerProtocol getMasterServer(NConfiguration conf)
          NeptuneMaster에 연결한다.
static TableSchema[] listTables(NConfiguration conf)
          모든 테이블 목록을 조회한다.
static java.io.IOException makeIOException(java.lang.Exception e)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NTableManager

public NTableManager()
Method Detail

connectTabletServer

public static DataServiceProtocol connectTabletServer(TabletInfo tabletInfo,
                                                      NConfiguration conf)
                                               throws java.io.IOException
Throws:
java.io.IOException

connectTabletServer

public static DataServiceProtocol connectTabletServer(java.lang.String hostName,
                                                      NConfiguration conf)
                                               throws java.io.IOException
Throws:
java.io.IOException

makeIOException

public static java.io.IOException makeIOException(java.lang.Exception e)

getMasterServer

public static TableManagerProtocol getMasterServer(NConfiguration conf)
                                            throws java.io.IOException
NeptuneMaster에 연결한다.

Parameters:
conf -
Returns:
Throws:
java.io.IOException

getLockService

public static com.nhncorp.pleiades.client.LockService getLockService(NConfiguration conf)
                                                              throws java.io.IOException
Throws:
java.io.IOException

listTables

public static TableSchema[] listTables(NConfiguration conf)
                                throws java.io.IOException
모든 테이블 목록을 조회한다.

Parameters:
conf -
Returns:
TableInfo[]
Throws:
java.io.IOException

dropTable

public static void dropTable(NConfiguration conf,
                             java.lang.String tableName)
                      throws java.io.IOException
테이블을 drop한다.

Parameters:
conf -
tableName -
Throws:
java.io.IOException

clear

public static void clear()