I am trying to set properties for an oozieclient in java which are read from a properties file. The properties file has 10 odd properties. Is there a way I can set these properties all at once and not have to read each key value pair from the file and then set them for the oozieclient?
OozieClient wc = new OozieClient(http://something:1100/oozie);
Properties conf = wc.createConfiguration();
conf.setProperty("jobTracker",....);
conf.setProperty("nameNode",......);
.
.
.
Instead of this, is there a way in which i can read these values from a properties file and set the values all at once?
You can read another property file and merge both:
With the file myfile.properties like:
Take a look at the Javadoc for Properties