mirror of https://github.com/apache/archiva.git
add time info
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1435207 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
acb0e671d4
commit
c0bfa19864
|
@ -34,6 +34,7 @@ import org.apache.archiva.redback.rbac.UserAssignment;
|
|||
import org.apache.archiva.redback.role.RoleManager;
|
||||
import org.apache.archiva.redback.users.UserManager;
|
||||
import org.apache.archiva.redback.components.registry.RegistryListener;
|
||||
import org.apache.commons.lang.time.StopWatch;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.context.ApplicationContext;
|
||||
|
@ -50,8 +51,6 @@ import java.util.Map.Entry;
|
|||
|
||||
/**
|
||||
* ConfigurationSynchronization
|
||||
*
|
||||
*
|
||||
*/
|
||||
@Service
|
||||
public class SecuritySynchronization
|
||||
|
@ -97,7 +96,8 @@ public class SecuritySynchronization
|
|||
return beans;
|
||||
}
|
||||
|
||||
public void afterConfigurationChange( org.apache.archiva.redback.components.registry.Registry registry, String propertyName, Object propertyValue )
|
||||
public void afterConfigurationChange( org.apache.archiva.redback.components.registry.Registry registry,
|
||||
String propertyName, Object propertyValue )
|
||||
{
|
||||
if ( ConfigurationNames.isManagedRepositories( propertyName ) && propertyName.endsWith( ".id" ) )
|
||||
{
|
||||
|
@ -108,7 +108,8 @@ public class SecuritySynchronization
|
|||
}
|
||||
}
|
||||
|
||||
public void beforeConfigurationChange( org.apache.archiva.redback.components.registry.Registry registry, String propertyName, Object propertyValue )
|
||||
public void beforeConfigurationChange( org.apache.archiva.redback.components.registry.Registry registry,
|
||||
String propertyName, Object propertyValue )
|
||||
{
|
||||
/* do nothing */
|
||||
}
|
||||
|
@ -176,6 +177,10 @@ public class SecuritySynchronization
|
|||
"Unable to initialize the Redback Security Environment, " + "no Environment Check components found." );
|
||||
}
|
||||
|
||||
StopWatch stopWatch = new StopWatch();
|
||||
stopWatch.reset();
|
||||
stopWatch.start();
|
||||
|
||||
List<String> violations = new ArrayList<String>();
|
||||
|
||||
for ( Entry<String, EnvironmentCheck> entry : checkers.entrySet() )
|
||||
|
@ -210,8 +215,12 @@ public class SecuritySynchronization
|
|||
throw new ArchivaException( "Unable to initialize Redback Security Environment, [" + violations.size()
|
||||
+ "] violation(s) encountered, See log for details." );
|
||||
}
|
||||
|
||||
stopWatch.stop();
|
||||
log.info( "time to execute all EnvironmentCheck: {} ms", stopWatch.getTime() );
|
||||
}
|
||||
|
||||
|
||||
private void assignRepositoryObserverToGuestUser( List<ManagedRepositoryConfiguration> repos )
|
||||
{
|
||||
for ( ManagedRepositoryConfiguration repoConfig : repos )
|
||||
|
|
|
@ -27,7 +27,8 @@
|
|||
|
||||
<appenders>
|
||||
<Console name="console" target="SYSTEM_OUT">
|
||||
<PatternLayout pattern="%d{HH:mm:ss.SSS} [%t] %-5level %logger{36} - %msg%n"/>
|
||||
<!--PatternLayout pattern="%d{HH:mm:ss.SSS} [%t] %-5level %logger{36} - %msg%n"/-->
|
||||
<PatternLayout pattern="%highlight{%d{HH:mm:ss.SSS} [%t] %-5level %logger{36} - %msg%n}" />
|
||||
</Console>
|
||||
|
||||
<!--RollingFile name="console" fileName="${logsDirectory}/archiva.log"
|
||||
|
|
Loading…
Reference in New Issue