@InterfaceAudience.Private public interface NamenodeProtocol
Modifier and Type | Field and Description |
---|---|
static int |
ACT_CHECKPOINT |
static int |
ACT_SHUTDOWN |
static int |
ACT_UNKNOWN |
static int |
FATAL |
static int |
NOTIFY |
static long |
versionID
Until version 6L, this class served as both
the client interface to the NN AND the RPC protocol used to
communicate with the NN.
|
Modifier and Type | Method and Description |
---|---|
void |
endCheckpoint(NamenodeRegistration registration,
CheckpointSignature sig)
A request to the active name-node to finalize
previously started checkpoint.
|
void |
errorReport(NamenodeRegistration registration,
int errorCode,
String msg)
Report to the active name-node an error occurred on a subordinate node.
|
ExportedBlockKeys |
getBlockKeys()
Get the current block keys
|
BlocksWithLocations |
getBlocks(DatanodeInfo datanode,
long size)
Get a list of blocks belonging to
datanode
whose total size equals size . |
RemoteEditLogManifest |
getEditLogManifest(long sinceTxId)
Return a structure containing details about all edit logs
available to be fetched from the NameNode.
|
long |
getMostRecentCheckpointTxId()
Get the transaction ID of the most recent checkpoint.
|
long |
getTransactionID() |
NamenodeRegistration |
registerSubordinateNamenode(NamenodeRegistration registration)
Register a subordinate name-node like backup node.
|
CheckpointSignature |
rollEditLog()
Closes the current edit log and opens a new one.
|
NamenodeCommand |
startCheckpoint(NamenodeRegistration registration)
A request to the active name-node to start a checkpoint.
|
NamespaceInfo |
versionRequest()
Request name-node version and storage information.
|
static final long versionID
static final int NOTIFY
static final int FATAL
static final int ACT_UNKNOWN
static final int ACT_SHUTDOWN
static final int ACT_CHECKPOINT
BlocksWithLocations getBlocks(DatanodeInfo datanode, long size) throws IOException
datanode
whose total size equals size
.datanode
- a data nodesize
- requested sizeIOException
- if size is less than or equal to 0 or
datanode does not existBalancer
ExportedBlockKeys getBlockKeys() throws IOException
IOException
long getTransactionID() throws IOException
IOException
long getMostRecentCheckpointTxId() throws IOException
IOException
CheckpointSignature rollEditLog() throws IOException
IOException
NamespaceInfo versionRequest() throws IOException
NamespaceInfo
identifying versions and storage information
of the name-nodeIOException
void errorReport(NamenodeRegistration registration, int errorCode, String msg) throws IOException
registration
- requesting node.errorCode
- indicates the errormsg
- free text description of the errorIOException
NamenodeRegistration registerSubordinateNamenode(NamenodeRegistration registration) throws IOException
NamenodeRegistration
of the node,
which this node has just registered with.IOException
NamenodeCommand startCheckpoint(NamenodeRegistration registration) throws IOException
registration
- the requesting nodeCheckpointCommand
if checkpoint is allowed.IOException
CheckpointCommand
,
NamenodeCommand
,
ACT_SHUTDOWN
void endCheckpoint(NamenodeRegistration registration, CheckpointSignature sig) throws IOException
registration
- the requesting nodesig
- CheckpointSignature
which identifies the checkpoint.IOException
RemoteEditLogManifest getEditLogManifest(long sinceTxId) throws IOException
sinceTxId
- return only logs that contain transactions >= sinceTxIdIOException
Copyright © 2013 Apache Software Foundation. All rights reserved.