From c3e33b96702241490c3a5fc5b30bffbbe41d7361 Mon Sep 17 00:00:00 2001 From: Olivier Lamy Date: Thu, 20 Dec 2012 20:33:35 +0000 Subject: [PATCH] fix name as it is related to Redback and not to Archiva git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1424675 13f79535-47bb-0310-9956-ffa450edef68 --- ... => RedbackRuntimeConfigurationAdmin.java} | 6 +- ...aultRedbackRuntimeConfigurationAdmin.java} | 62 +++++++++---------- ...ultArchivaRuntimeConfigurationService.java | 12 ++-- .../ldap/ArchivaLdapConnectionFactory.java | 6 +- .../ArchivaConfigurableUsersManager.java | 8 +-- .../ArchivaLockedAdminEnvironmentCheck.java | 6 +- .../ArchivaUserManagerAuthenticator.java | 10 +-- 7 files changed, 53 insertions(+), 57 deletions(-) rename archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/runtime/{ArchivaRuntimeConfigurationAdmin.java => RedbackRuntimeConfigurationAdmin.java} (86%) rename archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/{DefaultArchivaRuntimeConfigurationAdmin.java => DefaultRedbackRuntimeConfigurationAdmin.java} (87%) diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/runtime/ArchivaRuntimeConfigurationAdmin.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/runtime/RedbackRuntimeConfigurationAdmin.java similarity index 86% rename from archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/runtime/ArchivaRuntimeConfigurationAdmin.java rename to archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/runtime/RedbackRuntimeConfigurationAdmin.java index 116ac3065..3bb9a1199 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/runtime/ArchivaRuntimeConfigurationAdmin.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-api/src/main/java/org/apache/archiva/admin/model/runtime/RedbackRuntimeConfigurationAdmin.java @@ -25,12 +25,12 @@ import org.apache.archiva.admin.model.beans.RedbackRuntimeConfiguration; * @author Olivier Lamy * @since 1.4-M4 */ -public interface ArchivaRuntimeConfigurationAdmin +public interface RedbackRuntimeConfigurationAdmin { - RedbackRuntimeConfiguration getArchivaRuntimeConfiguration() + RedbackRuntimeConfiguration getRedbackRuntimeConfiguration() throws RepositoryAdminException; - void updateArchivaRuntimeConfiguration( RedbackRuntimeConfiguration redbackRuntimeConfiguration ) + void updateRedbackRuntimeConfiguration( RedbackRuntimeConfiguration redbackRuntimeConfiguration ) throws RepositoryAdminException; } diff --git a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultArchivaRuntimeConfigurationAdmin.java b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultRedbackRuntimeConfigurationAdmin.java similarity index 87% rename from archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultArchivaRuntimeConfigurationAdmin.java rename to archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultRedbackRuntimeConfigurationAdmin.java index 302e7bbcd..d8102738b 100644 --- a/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultArchivaRuntimeConfigurationAdmin.java +++ b/archiva-modules/archiva-base/archiva-repository-admin/archiva-repository-admin-default/src/main/java/org/apache/archiva/admin/repository/runtime/DefaultRedbackRuntimeConfigurationAdmin.java @@ -22,7 +22,7 @@ import net.sf.beanlib.provider.replicator.BeanReplicator; import org.apache.archiva.admin.model.RepositoryAdminException; import org.apache.archiva.admin.model.beans.LdapConfiguration; import org.apache.archiva.admin.model.beans.RedbackRuntimeConfiguration; -import org.apache.archiva.admin.model.runtime.ArchivaRuntimeConfigurationAdmin; +import org.apache.archiva.admin.model.runtime.RedbackRuntimeConfigurationAdmin; import org.apache.archiva.configuration.ArchivaConfiguration; import org.apache.archiva.configuration.Configuration; import org.apache.archiva.configuration.IndeterminateConfigurationException; @@ -45,8 +45,8 @@ import java.util.List; * @since 1.4-M4 */ @Service( "userConfiguration#archiva" ) -public class DefaultArchivaRuntimeConfigurationAdmin - implements ArchivaRuntimeConfigurationAdmin, UserConfiguration +public class DefaultRedbackRuntimeConfigurationAdmin + implements RedbackRuntimeConfigurationAdmin, UserConfiguration { protected Logger log = LoggerFactory.getLogger( getClass() ); @@ -64,7 +64,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin { try { - RedbackRuntimeConfiguration redbackRuntimeConfiguration = getArchivaRuntimeConfiguration(); + RedbackRuntimeConfiguration redbackRuntimeConfiguration = getRedbackRuntimeConfiguration(); // migrate or not data from redback if ( !redbackRuntimeConfiguration.isMigratedFromRedbackConfiguration() ) { @@ -101,7 +101,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin redbackRuntimeConfiguration.setMigratedFromRedbackConfiguration( true ); - updateArchivaRuntimeConfiguration( redbackRuntimeConfiguration ); + updateRedbackRuntimeConfiguration( redbackRuntimeConfiguration ); } @@ -111,7 +111,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin log.info( "redbackRuntimeConfiguration with empty userManagerImpls so force at least jdo implementation !" ); redbackRuntimeConfiguration.getUserManagerImpls().add( "jdo" ); - updateArchivaRuntimeConfiguration( redbackRuntimeConfiguration ); + updateRedbackRuntimeConfiguration( redbackRuntimeConfiguration ); } } @@ -121,12 +121,12 @@ public class DefaultArchivaRuntimeConfigurationAdmin } } - public RedbackRuntimeConfiguration getArchivaRuntimeConfiguration() + public RedbackRuntimeConfiguration getRedbackRuntimeConfiguration() { return build( archivaConfiguration.getConfiguration().getRedbackRuntimeConfiguration() ); } - public void updateArchivaRuntimeConfiguration( RedbackRuntimeConfiguration redbackRuntimeConfiguration ) + public void updateRedbackRuntimeConfiguration( RedbackRuntimeConfiguration redbackRuntimeConfiguration ) throws RepositoryAdminException { org.apache.archiva.configuration.RedbackRuntimeConfiguration @@ -188,10 +188,10 @@ public class DefaultArchivaRuntimeConfigurationAdmin if ( UserConfigurationKeys.USER_MANAGER_IMPL.equals( key ) ) { // possible false for others than archiva user manager - return getArchivaRuntimeConfiguration().getUserManagerImpls().get( 0 ); + return getRedbackRuntimeConfiguration().getUserManagerImpls().get( 0 ); } - RedbackRuntimeConfiguration conf = getArchivaRuntimeConfiguration(); + RedbackRuntimeConfiguration conf = getRedbackRuntimeConfiguration(); if ( conf.getConfigurationProperties().containsKey( key ) ) { @@ -207,7 +207,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin try { - updateArchivaRuntimeConfiguration( conf ); + updateRedbackRuntimeConfiguration( conf ); } catch ( RepositoryAdminException e ) { @@ -222,22 +222,22 @@ public class DefaultArchivaRuntimeConfigurationAdmin { if ( UserConfigurationKeys.LDAP_HOSTNAME.equals( key ) ) { - return getArchivaRuntimeConfiguration().getLdapConfiguration().getHostName(); + return getRedbackRuntimeConfiguration().getLdapConfiguration().getHostName(); } if ( UserConfigurationKeys.LDAP_CONTEX_FACTORY.equals( key ) ) { - return getArchivaRuntimeConfiguration().getLdapConfiguration().getContextFactory(); + return getRedbackRuntimeConfiguration().getLdapConfiguration().getContextFactory(); } if ( UserConfigurationKeys.LDAP_PASSWORD.equals( key ) ) { - return getArchivaRuntimeConfiguration().getLdapConfiguration().getPassword(); + return getRedbackRuntimeConfiguration().getLdapConfiguration().getPassword(); } if ( UserConfigurationKeys.LDAP_AUTHENTICATION_METHOD.equals( key ) ) { - return getArchivaRuntimeConfiguration().getLdapConfiguration().getAuthenticationMethod(); + return getRedbackRuntimeConfiguration().getLdapConfiguration().getAuthenticationMethod(); } - RedbackRuntimeConfiguration conf = getArchivaRuntimeConfiguration(); + RedbackRuntimeConfiguration conf = getRedbackRuntimeConfiguration(); if ( conf.getConfigurationProperties().containsKey( key ) ) { @@ -254,7 +254,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin conf.getConfigurationProperties().put( key, value ); try { - updateArchivaRuntimeConfiguration( conf ); + updateRedbackRuntimeConfiguration( conf ); } catch ( RepositoryAdminException e ) { @@ -267,7 +267,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin public int getInt( String key ) { - RedbackRuntimeConfiguration conf = getArchivaRuntimeConfiguration(); + RedbackRuntimeConfiguration conf = getRedbackRuntimeConfiguration(); if ( conf.getConfigurationProperties().containsKey( key ) ) { @@ -279,7 +279,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin conf.getConfigurationProperties().put( key, Integer.toString( value ) ); try { - updateArchivaRuntimeConfiguration( conf ); + updateRedbackRuntimeConfiguration( conf ); } catch ( RepositoryAdminException e ) { @@ -294,10 +294,10 @@ public class DefaultArchivaRuntimeConfigurationAdmin { if ( UserConfigurationKeys.LDAP_PORT.equals( key ) ) { - return getArchivaRuntimeConfiguration().getLdapConfiguration().getPort(); + return getRedbackRuntimeConfiguration().getLdapConfiguration().getPort(); } - RedbackRuntimeConfiguration conf = getArchivaRuntimeConfiguration(); + RedbackRuntimeConfiguration conf = getRedbackRuntimeConfiguration(); if ( conf.getConfigurationProperties().containsKey( key ) ) { @@ -309,7 +309,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin conf.getConfigurationProperties().put( key, Integer.toString( value ) ); try { - updateArchivaRuntimeConfiguration( conf ); + updateRedbackRuntimeConfiguration( conf ); } catch ( RepositoryAdminException e ) { @@ -322,7 +322,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin public boolean getBoolean( String key ) { - RedbackRuntimeConfiguration conf = getArchivaRuntimeConfiguration(); + RedbackRuntimeConfiguration conf = getRedbackRuntimeConfiguration(); if ( conf.getConfigurationProperties().containsKey( key ) ) { @@ -334,7 +334,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin conf.getConfigurationProperties().put( key, Boolean.toString( value ) ); try { - updateArchivaRuntimeConfiguration( conf ); + updateRedbackRuntimeConfiguration( conf ); } catch ( RepositoryAdminException e ) { @@ -349,10 +349,10 @@ public class DefaultArchivaRuntimeConfigurationAdmin { if ( UserConfigurationKeys.LDAP_SSL.equals( key ) ) { - return getArchivaRuntimeConfiguration().getLdapConfiguration().isSsl(); + return getRedbackRuntimeConfiguration().getLdapConfiguration().isSsl(); } - RedbackRuntimeConfiguration conf = getArchivaRuntimeConfiguration(); + RedbackRuntimeConfiguration conf = getRedbackRuntimeConfiguration(); if ( conf.getConfigurationProperties().containsKey( key ) ) { @@ -364,7 +364,7 @@ public class DefaultArchivaRuntimeConfigurationAdmin conf.getConfigurationProperties().put( key, Boolean.toString( value ) ); try { - updateArchivaRuntimeConfiguration( conf ); + updateRedbackRuntimeConfiguration( conf ); } catch ( RepositoryAdminException e ) { @@ -379,12 +379,12 @@ public class DefaultArchivaRuntimeConfigurationAdmin { List value = userConfiguration.getList( key ); - RedbackRuntimeConfiguration conf = getArchivaRuntimeConfiguration(); + RedbackRuntimeConfiguration conf = getRedbackRuntimeConfiguration(); // TODO concat values conf.getConfigurationProperties().put( key, "" ); try { - updateArchivaRuntimeConfiguration( conf ); + updateRedbackRuntimeConfiguration( conf ); } catch ( RepositoryAdminException e ) { @@ -399,11 +399,11 @@ public class DefaultArchivaRuntimeConfigurationAdmin { if ( UserConfigurationKeys.LDAP_BASEDN.equals( key ) ) { - return getArchivaRuntimeConfiguration().getLdapConfiguration().getBaseDn(); + return getRedbackRuntimeConfiguration().getLdapConfiguration().getBaseDn(); } if ( UserConfigurationKeys.LDAP_BINDDN.equals( key ) ) { - return getArchivaRuntimeConfiguration().getLdapConfiguration().getBindDn(); + return getRedbackRuntimeConfiguration().getLdapConfiguration().getBindDn(); } return userConfiguration.getConcatenatedList( key, defaultValue ); } diff --git a/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/main/java/org/apache/archiva/rest/services/DefaultArchivaRuntimeConfigurationService.java b/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/main/java/org/apache/archiva/rest/services/DefaultArchivaRuntimeConfigurationService.java index b62d59b35..46dbae3fd 100644 --- a/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/main/java/org/apache/archiva/rest/services/DefaultArchivaRuntimeConfigurationService.java +++ b/archiva-modules/archiva-web/archiva-rest/archiva-rest-services/src/main/java/org/apache/archiva/rest/services/DefaultArchivaRuntimeConfigurationService.java @@ -21,7 +21,7 @@ package org.apache.archiva.rest.services; import org.apache.archiva.admin.model.RepositoryAdminException; import org.apache.archiva.admin.model.beans.RedbackRuntimeConfiguration; import org.apache.archiva.admin.model.beans.LdapConfiguration; -import org.apache.archiva.admin.model.runtime.ArchivaRuntimeConfigurationAdmin; +import org.apache.archiva.admin.model.runtime.RedbackRuntimeConfigurationAdmin; import org.apache.archiva.redback.authentication.AuthenticationException; import org.apache.archiva.redback.authentication.Authenticator; import org.apache.archiva.redback.common.ldap.connection.LdapConnection; @@ -58,7 +58,7 @@ public class DefaultArchivaRuntimeConfigurationService implements ArchivaRuntimeConfigurationService { @Inject - private ArchivaRuntimeConfigurationAdmin archivaRuntimeConfigurationAdmin; + private RedbackRuntimeConfigurationAdmin redbackRuntimeConfigurationAdmin; @Inject @Named(value = "userManager#configurable") @@ -76,7 +76,7 @@ public class DefaultArchivaRuntimeConfigurationService { try { - return archivaRuntimeConfigurationAdmin.getArchivaRuntimeConfiguration(); + return redbackRuntimeConfigurationAdmin.getRedbackRuntimeConfiguration(); } catch ( RepositoryAdminException e ) { @@ -91,13 +91,13 @@ public class DefaultArchivaRuntimeConfigurationService { // has user manager impl changed ? boolean userManagerChanged = redbackRuntimeConfiguration.getUserManagerImpls().size() - != archivaRuntimeConfigurationAdmin.getArchivaRuntimeConfiguration().getUserManagerImpls().size(); + != redbackRuntimeConfigurationAdmin.getRedbackRuntimeConfiguration().getUserManagerImpls().size(); userManagerChanged = userManagerChanged || ( redbackRuntimeConfiguration.getUserManagerImpls().toString().hashCode() - != archivaRuntimeConfigurationAdmin.getArchivaRuntimeConfiguration().getUserManagerImpls().toString().hashCode() ); + != redbackRuntimeConfigurationAdmin.getRedbackRuntimeConfiguration().getUserManagerImpls().toString().hashCode() ); - archivaRuntimeConfigurationAdmin.updateArchivaRuntimeConfiguration( redbackRuntimeConfiguration ); + redbackRuntimeConfigurationAdmin.updateRedbackRuntimeConfiguration( redbackRuntimeConfiguration ); if ( userManagerChanged ) { diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/runtime/ldap/ArchivaLdapConnectionFactory.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/runtime/ldap/ArchivaLdapConnectionFactory.java index 6efdeea4c..43607e9bf 100644 --- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/runtime/ldap/ArchivaLdapConnectionFactory.java +++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/runtime/ldap/ArchivaLdapConnectionFactory.java @@ -20,7 +20,7 @@ package org.apache.archiva.web.runtime.ldap; import org.apache.archiva.admin.model.RepositoryAdminException; import org.apache.archiva.admin.model.beans.LdapConfiguration; -import org.apache.archiva.admin.model.runtime.ArchivaRuntimeConfigurationAdmin; +import org.apache.archiva.admin.model.runtime.RedbackRuntimeConfigurationAdmin; import org.apache.archiva.redback.common.ldap.connection.ConfigurableLdapConnectionFactory; import org.apache.archiva.redback.common.ldap.connection.LdapConnectionConfiguration; import org.springframework.stereotype.Service; @@ -41,7 +41,7 @@ public class ArchivaLdapConnectionFactory { @Inject - private ArchivaRuntimeConfigurationAdmin archivaRuntimeConfigurationAdmin; + private RedbackRuntimeConfigurationAdmin redbackRuntimeConfigurationAdmin; private LdapConnectionConfiguration ldapConnectionConfiguration; @@ -51,7 +51,7 @@ public class ArchivaLdapConnectionFactory try { LdapConfiguration ldapConfiguration = - archivaRuntimeConfigurationAdmin.getArchivaRuntimeConfiguration().getLdapConfiguration(); + redbackRuntimeConfigurationAdmin.getRedbackRuntimeConfiguration().getLdapConfiguration(); ldapConnectionConfiguration = new LdapConnectionConfiguration(); ldapConnectionConfiguration.setHostname( ldapConfiguration.getHostName() ); ldapConnectionConfiguration.setPort( ldapConfiguration.getPort() ); diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaConfigurableUsersManager.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaConfigurableUsersManager.java index 49a50a80c..f73785d7f 100644 --- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaConfigurableUsersManager.java +++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaConfigurableUsersManager.java @@ -19,7 +19,7 @@ package org.apache.archiva.web.security; */ import org.apache.archiva.admin.model.RepositoryAdminException; -import org.apache.archiva.admin.model.runtime.ArchivaRuntimeConfigurationAdmin; +import org.apache.archiva.admin.model.runtime.RedbackRuntimeConfigurationAdmin; import org.apache.archiva.redback.components.cache.Cache; import org.apache.archiva.redback.users.User; import org.apache.archiva.redback.users.UserManager; @@ -48,7 +48,7 @@ public class ArchivaConfigurableUsersManager { @Inject - private ArchivaRuntimeConfigurationAdmin archivaRuntimeConfigurationAdmin; + private RedbackRuntimeConfigurationAdmin redbackRuntimeConfigurationAdmin; @Inject private ApplicationContext applicationContext; @@ -67,7 +67,7 @@ public class ArchivaConfigurableUsersManager try { List userManagerImpls = - archivaRuntimeConfigurationAdmin.getArchivaRuntimeConfiguration().getUserManagerImpls(); + redbackRuntimeConfigurationAdmin.getRedbackRuntimeConfiguration().getUserManagerImpls(); log.info( "use userManagerImpls: '{}'", userManagerImpls ); userManagerPerId = new LinkedHashMap( userManagerImpls.size() ); @@ -90,7 +90,7 @@ public class ArchivaConfigurableUsersManager { try { - return archivaRuntimeConfigurationAdmin.getArchivaRuntimeConfiguration().isUseUsersCache(); + return redbackRuntimeConfigurationAdmin.getRedbackRuntimeConfiguration().isUseUsersCache(); } catch ( RepositoryAdminException e ) { diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLockedAdminEnvironmentCheck.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLockedAdminEnvironmentCheck.java index 8f6137b87..14284cb23 100644 --- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLockedAdminEnvironmentCheck.java +++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaLockedAdminEnvironmentCheck.java @@ -19,7 +19,7 @@ package org.apache.archiva.web.security; */ import org.apache.archiva.admin.model.RepositoryAdminException; -import org.apache.archiva.admin.model.runtime.ArchivaRuntimeConfigurationAdmin; +import org.apache.archiva.admin.model.runtime.RedbackRuntimeConfigurationAdmin; import org.apache.archiva.redback.integration.security.role.RedbackRoleConstants; import org.apache.archiva.redback.rbac.RBACManager; import org.apache.archiva.redback.rbac.RbacManagerException; @@ -64,7 +64,7 @@ public class ArchivaLockedAdminEnvironmentCheck private ApplicationContext applicationContext; @Inject - private ArchivaRuntimeConfigurationAdmin archivaRuntimeConfigurationAdmin; + private RedbackRuntimeConfigurationAdmin redbackRuntimeConfigurationAdmin; private List userManagers; @@ -73,7 +73,7 @@ public class ArchivaLockedAdminEnvironmentCheck throws RepositoryAdminException { List userManagerImpls = - archivaRuntimeConfigurationAdmin.getArchivaRuntimeConfiguration().getUserManagerImpls(); + redbackRuntimeConfigurationAdmin.getRedbackRuntimeConfiguration().getUserManagerImpls(); userManagers = new ArrayList( userManagerImpls.size() ); diff --git a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaUserManagerAuthenticator.java b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaUserManagerAuthenticator.java index f937ec8fa..da249dd54 100644 --- a/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaUserManagerAuthenticator.java +++ b/archiva-modules/archiva-web/archiva-web-common/src/main/java/org/apache/archiva/web/security/ArchivaUserManagerAuthenticator.java @@ -19,7 +19,7 @@ package org.apache.archiva.web.security; */ import org.apache.archiva.admin.model.RepositoryAdminException; -import org.apache.archiva.admin.model.runtime.ArchivaRuntimeConfigurationAdmin; +import org.apache.archiva.admin.model.runtime.RedbackRuntimeConfigurationAdmin; import org.apache.archiva.redback.authentication.AbstractAuthenticator; import org.apache.archiva.redback.authentication.AuthenticationConstants; import org.apache.archiva.redback.authentication.AuthenticationDataSource; @@ -28,7 +28,6 @@ import org.apache.archiva.redback.authentication.AuthenticationFailureCause; import org.apache.archiva.redback.authentication.AuthenticationResult; import org.apache.archiva.redback.authentication.Authenticator; import org.apache.archiva.redback.authentication.PasswordBasedAuthenticationDataSource; -import org.apache.archiva.redback.authentication.users.UserManagerAuthenticator; import org.apache.archiva.redback.policy.AccountLockedException; import org.apache.archiva.redback.policy.MustChangePasswordException; import org.apache.archiva.redback.policy.PasswordEncoder; @@ -44,11 +43,8 @@ import org.springframework.stereotype.Service; import javax.annotation.PostConstruct; import javax.inject.Inject; -import javax.inject.Named; import java.util.ArrayList; -import java.util.HashMap; import java.util.List; -import java.util.Map; /** * @author Olivier Lamy @@ -68,7 +64,7 @@ public class ArchivaUserManagerAuthenticator private ApplicationContext applicationContext; @Inject - private ArchivaRuntimeConfigurationAdmin archivaRuntimeConfigurationAdmin; + private RedbackRuntimeConfigurationAdmin redbackRuntimeConfigurationAdmin; private List userManagers; @@ -80,7 +76,7 @@ public class ArchivaUserManagerAuthenticator try { List userManagerImpls = - archivaRuntimeConfigurationAdmin.getArchivaRuntimeConfiguration().getUserManagerImpls(); + redbackRuntimeConfigurationAdmin.getRedbackRuntimeConfiguration().getUserManagerImpls(); userManagers = new ArrayList( userManagerImpls.size() );