/**
* Modify the config and start up the servers. The rpc and info ports for
* servers are guaranteed to use free ports.
* <p>
* NameNode and DataNode directory creation and configuration will be
* managed by this class.
*
* @param conf the base configuration to use in starting the servers. This
* will be modified as necessary.
* @param numDataNodes Number of DataNodes to start; may be zero
* @param format if true, format the NameNode and DataNodes before starting up
* @param racks array of strings indicating the rack that each DataNode is on
* @param hosts array of strings indicating the hostname of each DataNode
* @param numNameNodes Number of NameNodes to start;
* @param federation if true, we start it with federation configure;
*/
public MiniAvatarCluster(Configuration conf,
int numDataNodes,
boolean format,
String[] racks,
String[] hosts,
int numNameNodes,
boolean federation,
long[] simulatedCapacities)
throws IOException, ConfigException, InterruptedException {
this(new Builder(conf).numDataNodes(numDataNodes).format(format)
.racks(racks)
.hosts(hosts)
.numNameNodes(numNameNodes)
.federation(federation)
.simulatedCapacities(simulatedCapacities));
}
MiniAvatarCluster.java 文件源码
java
阅读 31
收藏 0
点赞 0
评论 0
项目:hadoop-EAR
作者:
评论列表
文章目录