KAFKA-18483: Disable Log4jController and Loggers if Log4j Core absent#18496
KAFKA-18483: Disable Log4jController and Loggers if Log4j Core absent#18496chia7712 merged 9 commits intoapache:trunkfrom
Log4jController and Loggers if Log4j Core absent#18496Conversation
|
@ppkarwasz could you please fix the conflicts? I will get a quick review after the conflicts get fixed. |
|
A label of 'needs-attention' was automatically added to this PR in order to raise the |
Sure, I'll fix the conflicts and check out the failing tests today. |
…sent If Log4j Core is absent, most calls to `Log4jController` and `Loggers` will end up with a `NoClassDefFoundError`. This changeset: - Profits from the major version bump to rename `k.util.Log4jController` to `LoggingController`. - Removes `o.a.l.l.Level` from the signature of public methods of `o.a.k.connect.runtime.Loggers` and replaces it with `String`. - Provides an additional no-op implementation of `k.util.LoggingController` and `o.a.k.connect.runtime.Loggers`: if Log4j Core is not present on the runtime classpath the no-op implementation will be used.
b6a1610 to
9c36ec8
Compare
|
A label of 'needs-attention' was automatically added to this PR in order to raise the |
|
Note: Before submitting the PR I checked it with |
there are some flaky test in trunk branch. I feel they are unrelated to this PR :) |
|
I hit the test failure locally when on your branch: |
Thanks somehow Gradle didn't mark the build as failed, even if this test didn't work. Fixed in b382950 |
chia7712
left a comment
There was a problem hiding this comment.
@ppkarwasz thanks for the patch! Sorry for the late review, I was busy with the Lunar New Year festivities :(
|
@ppkarwasz Could you please fix the conflicts ? |
chia7712
left a comment
There was a problem hiding this comment.
LGTM
Test the patch on my local with JMC and changing the logger levels works well.
…ent (apache#18496) If Log4j Core is absent, most calls to Log4jController and Loggers will end up with a NoClassDefFoundError. This changeset: - Profits from the major version bump to rename k.util.Log4jController to LoggingController. - Removes o.a.l.l.Level from the signature of public methods of o.a.k.connect.runtime.Loggers and replaces it with String. - Provides an additional no-op implementation of k.util.LoggingController and o.a.k.connect.runtime.Loggers: if Log4j Core is not present on the runtime classpath the no-op implementation will be used. Reviewers: Mickael Maison <mickael.maison@gmail.com>, Chia-Ping Tsai <chia7712@gmail.com>
…ent (apache#18496) If Log4j Core is absent, most calls to Log4jController and Loggers will end up with a NoClassDefFoundError. This changeset: - Profits from the major version bump to rename k.util.Log4jController to LoggingController. - Removes o.a.l.l.Level from the signature of public methods of o.a.k.connect.runtime.Loggers and replaces it with String. - Provides an additional no-op implementation of k.util.LoggingController and o.a.k.connect.runtime.Loggers: if Log4j Core is not present on the runtime classpath the no-op implementation will be used. Reviewers: Mickael Maison <mickael.maison@gmail.com>, Chia-Ping Tsai <chia7712@gmail.com>
If Log4j Core is absent, most calls to
Log4jControllerandLoggerswill end up with aNoClassDefFoundError.This changeset:
k.util.Log4jControllertoLoggingController.o.a.l.l.Levelfrom the signature of public methods ofo.a.k.connect.runtime.Loggersand replaces it withString.k.util.LoggingControllerando.a.k.connect.runtime.Loggers: if Log4j Core is not present on the runtime classpath the no-op implementation will be used.Committer Checklist (excluded from commit message)