use of org.wso2.carbon.identity.secret.mgt.core.dao.SecretDAO in project carbon-identity-framework by wso2.
the class SecretManagerComponent method activate.
/**
* Register SecretManager as an OSGI service.
*
* @param componentContext OSGI service component context.
*/
@Activate
protected void activate(ComponentContext componentContext) {
BundleContext bundleContext = componentContext.getBundleContext();
SecretDAO secretDAO = new SecretDAOImpl();
bundleContext.registerService(SecretDAO.class.getName(), new CachedBackedSecretDAO(secretDAO), null);
bundleContext.registerService(SecretManager.class.getName(), new SecretManagerImpl(), null);
bundleContext.registerService(SecretResolveManager.class.getName(), new SecretResolveManagerImpl(), null);
SecretManagerComponentDataHolder.getInstance().setSecretManagementEnabled(isSecretManagementEnabled());
}
use of org.wso2.carbon.identity.secret.mgt.core.dao.SecretDAO in project carbon-identity-framework by wso2.
the class SecretManagerTest method prepareConfigs.
private void prepareConfigs() {
SecretDAO secretDAO = new SecretDAOImpl();
SecretManagerComponentDataHolder.getInstance().setSecretDAOS(Collections.singletonList(secretDAO));
mockCarbonContextForTenant(SUPER_TENANT_ID, SUPER_TENANT_DOMAIN_NAME);
mockIdentityTenantUtility();
secretManager = new SecretManagerImpl();
secretResolveManager = new SecretResolveManagerImpl();
}
Aggregations