apex-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pramod Immaneni <pra...@datatorrent.com>
Subject Re: DTLoggerFactory behavior
Date Wed, 20 Apr 2016 08:47:56 GMT
Chandni,

According to log4j documentation here

https://logging.apache.org/log4j/1.2/manual.html

Example 3
Logger
nameAssigned
levelInherited
level
root Proot Proot
X Px Px
X.Y none Px
X.Y.Z Pxyz Pxyz


the sub-package override should be supported by default. Could it be the
reason it is not happening is because of the way we are changing it
dynamically at runtime.

Thanks

On Tue, Apr 19, 2016 at 2:30 PM, Chandni Singh <chandni@datatorrent.com>
wrote:

> Hi,
>
> Initially when DTLoggerFactory was created it's behavior was not very well
> defined with respect to packages and sub-packages.
>
> As we are moving to org.apache.apex package,  I am having trouble setting
> log level to DEBUG for all org.apache.apex.* classes.
>
> I suspect this is because in some log4j.properties org.apache=INFO
> overrides org.apache.apex=DEBUG and also the order in which these entries
> are encountered changes the behavior.
>
> We need to fix this and this is what I am thinking of doing.
>
> Packages are represented as a prefix tree (trie). For example:
>              org
>              |
>       apache (INFO)
>         |
>     apex (DEBUG)
>
> If org.apache is set to INFO but org.apache.apex is set to DEBUG then all
> classes which are sub-packages of org.apache.apex will log at DEBUG level
>
> Classes which are sub-packages of org.apache but not org.apache.apex will
> log at INFO level.
>
> Will create a JIRA for this and start the work soon.
>
> Thanks,
> Chandni
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message