|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.hadoop.dfs.DatanodeID org.apache.hadoop.dfs.DatanodeInfo
public class DatanodeInfo
DatanodeInfo represents the status of a DataNode. This object is used for communication in the Datanode Protocol and the Client Protocol.
Nested Class Summary | |
---|---|
static class |
DatanodeInfo.AdminStates
|
Field Summary | |
---|---|
protected DatanodeInfo.AdminStates |
adminState
|
protected long |
capacity
|
protected long |
lastUpdate
|
protected long |
remaining
|
protected int |
xceiverCount
|
Fields inherited from class org.apache.hadoop.dfs.DatanodeID |
---|
infoPort, name, storageID |
Method Summary | |
---|---|
long |
getCapacity()
The raw capacity. |
String |
getDatanodeReport()
A formatted string for reporting the status of the DataNode. |
String |
getHostName()
|
long |
getLastUpdate()
The time when this information was accurate. |
int |
getLevel()
Return this node's level in the tree. |
String |
getNetworkLocation()
rack name |
Node |
getParent()
Return this node's parent |
String |
getPath()
|
long |
getRemaining()
The raw free space. |
int |
getXceiverCount()
number of active connections |
void |
readFields(DataInput in)
Reads the fields of this object from in . |
void |
setHostName(String host)
|
void |
setLevel(int level)
|
void |
setParent(Node parent)
|
void |
write(DataOutput out)
Writes the fields of this object to out . |
Methods inherited from class org.apache.hadoop.dfs.DatanodeID |
---|
compareTo, equals, getHost, getInfoPort, getName, getPort, getStorageID, hashCode, toString |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.apache.hadoop.net.Node |
---|
getName |
Field Detail |
---|
protected long capacity
protected long remaining
protected long lastUpdate
protected int xceiverCount
protected DatanodeInfo.AdminStates adminState
Method Detail |
---|
public long getCapacity()
public long getRemaining()
public long getLastUpdate()
public int getXceiverCount()
public String getNetworkLocation()
getNetworkLocation
in interface Node
public String getPath()
public String getHostName()
public void setHostName(String host)
public String getDatanodeReport()
public Node getParent()
getParent
in interface Node
public void setParent(Node parent)
public int getLevel()
getLevel
in interface Node
public void setLevel(int level)
public void write(DataOutput out) throws IOException
Writable
out
.
write
in interface Writable
write
in class DatanodeID
IOException
public void readFields(DataInput in) throws IOException
Writable
in
. For efficiency,
implementations should attempt to re-use storage in the existing object
where possible.
readFields
in interface Writable
readFields
in class DatanodeID
IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |