org.apache.hadoop.dfs
Class DatanodeDescriptor
java.lang.Object
org.apache.hadoop.dfs.DatanodeID
org.apache.hadoop.dfs.DatanodeInfo
org.apache.hadoop.dfs.DatanodeDescriptor
- All Implemented Interfaces:
- Comparable, Writable, WritableComparable, Node
public class DatanodeDescriptor
- extends DatanodeInfo
DatanodeDescriptor tracks stats on a given DataNode,
such as available storage capacity, last update time, etc.,
and maintains a set of blocks stored on the datanode.
This data structure is a data structure that is internal
to the namenode. It is *not* sent over-the-wire to the Client
or the Datnodes. Neither is it stored persistently in the
fsImage.
- Author:
- Mike Cafarella, Konstantin Shvachko
Field Summary |
protected boolean |
isAlive
|
Constructor Summary |
DatanodeDescriptor()
Default constructor |
DatanodeDescriptor(DatanodeID nodeID)
DatanodeDescriptor constructor |
DatanodeDescriptor(DatanodeID nodeID,
long capacity,
long remaining,
int xceiverCount)
DatanodeDescriptor constructor |
DatanodeDescriptor(DatanodeID nodeID,
String networkLocation)
DatanodeDescriptor constructor |
DatanodeDescriptor(DatanodeID nodeID,
String networkLocation,
String hostName)
DatanodeDescriptor constructor |
DatanodeDescriptor(DatanodeID nodeID,
String networkLocation,
String hostName,
long capacity,
long remaining,
int xceiverCount)
DatanodeDescriptor constructor |
Methods inherited from class org.apache.hadoop.dfs.DatanodeInfo |
getCapacity, getDatanodeReport, getHostName, getLastUpdate, getLevel, getNetworkLocation, getParent, getPath, getRemaining, getXceiverCount, readFields, setHostName, setLevel, setParent, write |
Methods inherited from interface org.apache.hadoop.net.Node |
getName |
isAlive
protected boolean isAlive
DatanodeDescriptor
public DatanodeDescriptor()
- Default constructor
DatanodeDescriptor
public DatanodeDescriptor(DatanodeID nodeID)
- DatanodeDescriptor constructor
- Parameters:
nodeID
- id of the data node
DatanodeDescriptor
public DatanodeDescriptor(DatanodeID nodeID,
String networkLocation)
- DatanodeDescriptor constructor
- Parameters:
nodeID
- id of the data nodenetworkLocation
- location of the data node in network
DatanodeDescriptor
public DatanodeDescriptor(DatanodeID nodeID,
String networkLocation,
String hostName)
- DatanodeDescriptor constructor
- Parameters:
nodeID
- id of the data nodenetworkLocation
- location of the data node in networkhostName
- it could be different from host specified for DatanodeID
DatanodeDescriptor
public DatanodeDescriptor(DatanodeID nodeID,
long capacity,
long remaining,
int xceiverCount)
- DatanodeDescriptor constructor
- Parameters:
nodeID
- id of the data nodecapacity
- capacity of the data noderemaining
- remaing capacity of the data nodexceiverCount
- # of data transfers at the data node
DatanodeDescriptor
public DatanodeDescriptor(DatanodeID nodeID,
String networkLocation,
String hostName,
long capacity,
long remaining,
int xceiverCount)
- DatanodeDescriptor constructor
- Parameters:
nodeID
- id of the data nodenetworkLocation
- location of the data node in networkcapacity
- capacity of the data noderemaining
- remaing capacity of the data nodexceiverCount
- # of data transfers at the data node
Copyright © 2006 The Apache Software Foundation