[ 
https://issues.apache.org/jira/browse/HADOOP-4757?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12653252#action_12653252
 ] 

Steve Loughran commented on HADOOP-4757:
----------------------------------------

I would personally argue against having any log4j config file in a JAR, as 
trying to track down the origin of broken logging settings in a big application 
is painful. Indeed, it is the origin of the <whichresource> task in Ant

{{<whichresource resource="/log4j.properties" property="log4j.url" >}}

A key issue here is that when hadoop-core is used as a client library, that 
client may pick up the hadoop log policy not its own. 

Even in a cluster, Logging settings are very installation specific; embedding 
them in a JAR means you need to edit the JAR to replace them. If all Log4J 
settings were omitted and yet could be picked up from a conf directory, all 
would be well.

Maybe the solution here is to permit site-conf jars that contain only the 
configuration files; you could switch to a different configuration JAR without 
rebuilding/redistributing hadoop-core itself.

> Replace log4j.properties with log4j.xml
> ---------------------------------------
>
>                 Key: HADOOP-4757
>                 URL: https://issues.apache.org/jira/browse/HADOOP-4757
>             Project: Hadoop Core
>          Issue Type: Improvement
>            Reporter: Alex Loddengaard
>            Assignee: Alex Loddengaard
>            Priority: Minor
>         Attachments: log4j_xml_config.patch, log4j_xml_config_v2.patch
>
>
> Certain log4j features are not configurable via the log4j.properties file, 
> not to mention the log4j.properties file is messy.  For this reason, we 
> should transition to a XML file to configure log4j.  The .properties vs. .xml 
> argument has only come up in HADOOP-211, where the XML configuration was 
> vetoed for Tomcat integration issues.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to