Patrick Rhomberg resolved GEODE-4902.
    Resolution: Fixed

> Log markers filter some messages pathologically
> -----------------------------------------------
>                 Key: GEODE-4902
>                 URL: https://issues.apache.org/jira/browse/GEODE-4902
>             Project: Geode
>          Issue Type: Bug
>          Components: docs, logging
>            Reporter: Patrick Rhomberg
>            Assignee: Patrick Rhomberg
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 1.6.0
>          Time Spent: 1h 10m
>  Remaining Estimate: 0h
> Many logging calls across all log levels are marked with 
> {{o.a.g.internal.logging.log4j.LogMarker}} markers for selective enabling and 
> debugging.  All these markers have a parent marker {{GEODE_VERBOSE}}.  
> However, per the default given in 
> {{geode-core/src/main/resources/log4j2.xml}}, this parent marker is set to 
> filter log messages.
> Many of these log messages are invoked at the {{info}} level, suggesting an 
> expectation that the message would be seen.
> These markers should be refactored to (a) include by default markers that 
> commonly or exclusively appear in coarse-grained logging levels, and (b) to 
> reorganize the markers' parent/child relationships so that they are not 
> blanket-disabled by default.  Only those markers attacked to more verbose 
> logging should be disabled by default.
> ---
> Additionally, the log classes {{FastLogger}} and {{LogWriterLogger}} are 
> themselves slightly pathological.  Notably, the former overrides some 
> {{isEnabled}} aliases but leaves exposed default many of the root method 
> signatures.  The latter pathologically includes a reference to itself as a 
> field unto itself in the lines:
> {noformat}
> private final ExtendedLoggerWrapper logWrapper;
> // ...
>   private LogWriterLogger(final Logger logger, final String connectionName,
>       final boolean isSecure) {
>     super((AbstractLogger) logger, logger.getName(), 
> logger.getMessageFactory());
>     this.logWrapper = this;
>     // ...
>   }
> {noformat}
> These classes could use refactoring in their own right, perhaps as a separate 
> child ticket.
> ---------
> Docs: While only the top-level marker (formerly {{GEMFIRE_VERBOSE}}, now 
> {{GEODE_VERBOSE}}) is documented, it may be worth a release note that the 
> Log4J2 markers have changed, and anyone be using a custom log4j2.xml after 
> discovering these markers will have to update that XML to the new markers.

This message was sent by Atlassian JIRA

Reply via email to