use of jetbrains.exodus.InvalidSettingException in project pwm by pwm-project.
the class XodusLocalDB method makeEnvironmentConfig.
private EnvironmentConfig makeEnvironmentConfig(final Map<String, String> initParameters) {
final EnvironmentConfig environmentConfig = new EnvironmentConfig();
environmentConfig.setEnvCloseForcedly(true);
environmentConfig.setMemoryUsage(50 * 1024 * 1024);
environmentConfig.setEnvGatherStatistics(true);
for (final Map.Entry<String, String> entry : initParameters.entrySet()) {
final String key = entry.getKey();
final String value = entry.getValue();
final Map<String, String> singleMap = Collections.singletonMap(key, value);
try {
environmentConfig.setSettings(singleMap);
LOGGER.trace("set env setting from appProperty: " + key + "=" + value);
} catch (InvalidSettingException e) {
LOGGER.warn("problem setting configured env settings: " + e.getMessage());
}
}
return environmentConfig;
}
Aggregations