List of usage examples for org.apache.commons.configuration.reloading ManagedReloadingStrategy ManagedReloadingStrategy
ManagedReloadingStrategy
From source file:org.jhub1.agent.configuration.PropertiesImpl.java
public PropertiesImpl() throws ConfigurationException { reloadingStrategy = new ManagedReloadingStrategy(); config = new CompositeConfiguration(); config.addConfiguration(new SystemConfiguration()); config.addConfiguration(new PropertiesConfiguration("agent.properties")); config.addConfiguration(new PropertiesConfiguration("agent.internal.properties")); try {//from w w w . j a v a 2s . co m XMLConfiguration fromFile = new XMLConfiguration("settings.xml"); fromFile.setReloadingStrategy(reloadingStrategy); reloadFlag = true; config.addConfiguration(fromFile); } catch (ConfigurationException ce) { log.error("Problem with loading custom configuration: " + ce.getMessage()); } config.addConfiguration(new XMLConfiguration("settings.default.xml")); }