Thank you Harsh and Chris. This really helps!
-Karthiek
On Fri, Feb 22, 2013 at 2:46 PM, Chris Nauroth wrote:
> Regarding your question about a pluggable module to control placement of
> data, try taking a look at the abstract class BlockPlacementPolicy and
> BlockPlacementPolicyDefault, which i
Regarding your question about a pluggable module to control placement of
data, try taking a look at the abstract class BlockPlacementPolicy and
BlockPlacementPolicyDefault, which is its default implementation.
On branch-1, you can find these classes
at src/hdfs/org/apache/hadoop/hdfs/server/nameno
There's no filesystem (i.e. client) level APIs to do this, but the
Balancer tool of HDFS does exactly this. Reading its sources should
let you understand what kinda calls you need to make to reuse the
balancer protocol and achieve what you need.
In trunk, the balancer is at
hadoop-hdfs-project/had