Description
I think we should add a getAverageLoadOneMinute RPC in ClientDatanodeProtocol to get the average load of the datanode in recent one minute.
We can use this RPC in HDFS client side and other places. For example, in method addDatanode2ExistingPipeline. We can choose the datanode with less average load as source datanode and then transfer block to new datanode which is added to existed pipeline.