001/** 002 * Licensed to the Apache Software Foundation (ASF) under one 003 * or more contributor license agreements. See the NOTICE file 004 * distributed with this work for additional information 005 * regarding copyright ownership. The ASF licenses this file 006 * to you under the Apache License, Version 2.0 (the 007 * "License"); you may not use this file except in compliance 008 * with the License. You may obtain a copy of the License at 009 * 010 * http://www.apache.org/licenses/LICENSE-2.0 011 * 012 * Unless required by applicable law or agreed to in writing, software 013 * distributed under the License is distributed on an "AS IS" BASIS, 014 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 015 * See the License for the specific language governing permissions and 016 * limitations under the License. 017 */ 018package org.apache.hadoop.hdfs.server.datanode; 019 020import org.apache.hadoop.classification.InterfaceAudience; 021import org.apache.hadoop.classification.InterfaceStability; 022 023import java.util.Map; 024 025/** 026 * 027 * This is the JMX management interface for data node information 028 */ 029@InterfaceAudience.Public 030@InterfaceStability.Stable 031public interface DataNodeMXBean { 032 033 /** 034 * Gets the version of Hadoop. 035 * 036 * @return the version of Hadoop 037 */ 038 public String getVersion(); 039 040 /** 041 * Gets the rpc port. 042 * 043 * @return the rpc port 044 */ 045 public String getRpcPort(); 046 047 /** 048 * Gets the http port. 049 * 050 * @return the http port 051 */ 052 public String getHttpPort(); 053 054 /** 055 * Gets the namenode IP addresses 056 * 057 * @return the namenode IP addresses that the datanode is talking to 058 */ 059 public String getNamenodeAddresses(); 060 061 /** 062 * Gets the information of each volume on the Datanode. Please 063 * see the implementation for the format of returned information. 064 * 065 * @return the volume info 066 */ 067 public String getVolumeInfo(); 068 069 /** 070 * Gets the cluster id. 071 * 072 * @return the cluster id 073 */ 074 public String getClusterId(); 075 076 /** 077 * Returns an estimate of the number of Datanode threads 078 * actively transferring blocks. 079 */ 080 public int getXceiverCount(); 081 082 /** 083 * Gets the network error counts on a per-Datanode basis. 084 */ 085 public Map<String, Map<String, Long>> getDatanodeNetworkCounts(); 086}