use of org.gluu.persist.exception.BasePersistenceException in project oxAuth by GluuFederation.
the class ConfigurationFactory method loadConfigurationFromLdap.
private Conf loadConfigurationFromLdap(String... returnAttributes) {
final PersistenceEntryManager ldapManager = persistenceEntryManagerInstance.get();
final String dn = this.baseConfiguration.getString("oxauth_ConfigurationEntryDN");
try {
final Conf conf = ldapManager.find(dn, Conf.class, returnAttributes);
return conf;
} catch (BasePersistenceException ex) {
ex.printStackTrace();
log.error(ex.getMessage());
}
return null;
}
use of org.gluu.persist.exception.BasePersistenceException in project oxAuth by GluuFederation.
the class AppInitializer method loadConfiguration.
private GluuConfiguration loadConfiguration(PersistenceEntryManager localPersistenceEntryManager, String... persistenceReturnAttributes) {
String configurationDn = configurationFactory.getBaseDn().getConfiguration();
if (StringHelper.isEmpty(configurationDn)) {
return null;
}
GluuConfiguration configuration = null;
try {
configuration = localPersistenceEntryManager.find(configurationDn, GluuConfiguration.class, persistenceReturnAttributes);
} catch (BasePersistenceException ex) {
log.error("Failed to load global configuration entry from Ldap", ex);
return null;
}
return configuration;
}
Aggregations