Example usage for org.apache.hadoop.hdfs.server.namenode SecondaryNameNode SecondaryNameNode

List of usage examples for org.apache.hadoop.hdfs.server.namenode SecondaryNameNode SecondaryNameNode

Introduction

In this page you can find the example usage for org.apache.hadoop.hdfs.server.namenode SecondaryNameNode SecondaryNameNode.

Prototype

public SecondaryNameNode(Configuration conf) throws IOException 

Source Link

Document

Create a connection to the primary namenode.

Usage

From source file:io.fabric8.hadoop.hdfs.SecondaryNameNodeFactory.java

License:Apache License

@Override
protected SecondaryNameNode doCreate(Dictionary properties) throws Exception {
    Configuration conf = new Configuration();
    for (Enumeration e = properties.keys(); e.hasMoreElements();) {
        Object key = e.nextElement();
        Object val = properties.get(key);
        conf.set(key.toString(), val.toString());
    }/*from   ww  w.  j  av a2s  .  c  o m*/
    SecondaryNameNode secondaryNameNode = new SecondaryNameNode(conf);
    new Daemon(secondaryNameNode).start();
    return secondaryNameNode;
}