public class Log4JHierarchyInit extends Object implements org.springframework.context.ApplicationContextAware
Alfresco modules can provide their own log4j.properties file, which augments/overrides the global log4j.properties within the Alfresco webapp. Within the module's source tree, suppose you create:
config/alfresco/module/{module.id}/log4j.propertiesAt deployment time, this log4j.properties file will be placed in:
WEB-INF/classes/alfresco/module/{module.id}/log4j.propertiesWhere {module.id} is whatever value is set within the AMP's module.properties file. For details, see: Developing an Alfresco Module
For example, if {module.id} is "org.alfresco.module.someModule", then within your source code you'll have:
config / alfresco / module / org.alfresco.module.someModule / log4j.propertiesThis would be deployed to:
WEB - INF / classes / alfresco / module / org.alfresco.module.someModule / log4j.properties
Constructor and Description |
---|
Log4JHierarchyInit() |
Modifier and Type | Method and Description |
---|---|
void |
init() |
void |
setApplicationContext(org.springframework.context.ApplicationContext applicationContext) |
void |
setExtraLog4jUrls(List<String> urls)
Loads a set of augmenting/overriding log4j.properties files from locations specified via an array of Srping URLS.
|
public void setExtraLog4jUrls(List<String> urls)
This function supports Spring's syntax for retrieving multiple class path resources with the same name,
via the "classpath*:" prefix. For details, see: PathMatchingResourcePatternResolver
.
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) throws org.springframework.beans.BeansException
setApplicationContext
in interface org.springframework.context.ApplicationContextAware
org.springframework.beans.BeansException
public void init()
Copyright © 2005–2017 Alfresco Software. All rights reserved.