You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by kawamuray <gi...@git.apache.org> on 2017/01/30 08:20:40 UTC

[GitHub] kafka pull request #2465: KAFKA-4710: Interpolate log4j's logging source int...

GitHub user kawamuray opened a pull request:

    https://github.com/apache/kafka/pull/2465

    KAFKA-4710: Interpolate log4j's logging source interpretation to correct loation info of logs written through trait methods

    Issue: https://issues.apache.org/jira/browse/KAFKA-4710
    
    This PR fixes location information of log4j `LoggingEvent` which is currently given wrongly due to indirect logger method invocation through Logging trait method.
    By introducing custom `LoggingEvent` which manually traverses stack trace to find a correct location where the logs are originally written, an appender can now obtain the correct location instead of somewhere inside the `Logging.scala`.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/kawamuray/kafka KAFKA-4710-correct-log4j-location

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/kafka/pull/2465.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #2465
    
----
commit 75575dea7f4b4e0b42f5f67cf0160d28fd88e14a
Author: Yuto Kawamura <ka...@gmail.com>
Date:   2017-01-30T06:07:30Z

    KAFKA-4710: Add unit tests for Logging trait

commit a9b27e6cb2d61addbd0f4c538799bf9d92ee9bd4
Author: Yuto Kawamura <ka...@gmail.com>
Date:   2017-01-30T06:14:33Z

    KAFKA-4710: Interpolate log4j's logging source interpretation to correct loation info of logs written through trait methods
    
    Also,
    - Make all logging methods `final` to avoid unexpected call stack corruption
    - Refactoring some fields modifier to make their scope clearer

commit be79c4afb73db86440d04769c2cd988905fcd7e9
Author: Yuto Kawamura <ka...@gmail.com>
Date:   2017-01-30T06:42:35Z

    MINOR: Code cleanup for Logging trait

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] kafka pull request #2465: KAFKA-4710: Interpolate log4j's logging source int...

Posted by kawamuray <gi...@git.apache.org>.
Github user kawamuray closed the pull request at:

    https://github.com/apache/kafka/pull/2465


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---