Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve servicetalk-test-resources/log4j2.xml #1181

Merged
merged 1 commit into from
Oct 15, 2020

Conversation

idelpivnitskiy
Copy link
Member

Motivation:

Wire logger and h2 frame logger are controlled by the logger configuration
after #1123. It allows us to use these logger names in tests and enabled them
via system property when required for local debugging.
Having 2 different logger names for client and server controlled by a single
system property does not help much. We can use a thread name to understand
if a logger statement belongs to a client or to a server. A single logger name
simplifies usage in tests.

Modifications:

  • Keep only a single servicetalk-tests-wire-logger logger name;
  • Add servicetalk-tests-h2-frame-logger logger name and
    servicetalk.logger.h2FrameLogLevel system property to control visibility
    for h2 frames;
  • Update all tests to use new names;

Result:

Separate system properties to control wire logger and h2 frame logger.

Motivation:

Wire logger and h2 frame logger are controlled by the logger configuration
after apple#1123. It allows us to use these logger names in tests and enabled them
via system property when required for local debugging.
Having 2 different logger names for client and server controlled by a single
system property does not help much. We can use thread name to understand if
a logger statement belongs to a client or to a server. A single logger name
simplifies usage in tests.

Modifications:

- Keep only a single `servicetalk-tests-wire-logger` logger name;
- Add `servicetalk-tests-h2-frame-logger` logger name and
`servicetalk.logger.h2FrameLogLevel` system property to control visibility
for h2 frames;
- Update all tests to use new names;

Result:

Separate system property to control wire logger and h2 frame logger.
@idelpivnitskiy idelpivnitskiy merged commit a0bf19d into apple:main Oct 15, 2020
@idelpivnitskiy idelpivnitskiy deleted the fix-test-loggers branch October 15, 2020 17:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants