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

Add a logback appender that can be added to a config to export context IDs #1165

Merged
merged 4 commits into from
Sep 4, 2020

Conversation

anuraaga
Copy link
Contributor

@anuraaga anuraaga commented Sep 3, 2020

Heavily inspired by Armeria, even copied a file as-is

https://github.com/line/armeria/blob/master/logback/src/main/java/com/linecorp/armeria/common/logback/RequestContextExportingAppender.java

While MDC integration can cover non-logback / log4j, I think directly integrating with them like this and the log4j module work well. This is why I'm hoping to be able to inject logback.xml using auto instrumentation at some point though :)

/cc @trustin

@@ -0,0 +1,19 @@
This product contains a modified part of Armeria, distributed by LINE:
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would generally copy the license header into the file I copied as well, but spotless deletes the second header if I try. For now I've added this NOTICE but let me know if there's something I should do here.

@iNikem
Copy link
Contributor

iNikem commented Sep 3, 2020

Should you update some documentation as well? At least README.md or some sort of highly visible link to module specific readme

@anuraaga
Copy link
Contributor Author

anuraaga commented Sep 3, 2020

I was thinking of adding to top-level README.md but since this isn't supported by agent yet thought it might be confusing. How about I struggle try to set up auto instrumentation in a followup and otherwise will start a dedicated section for manual-only instrumentations we provide.

@anuraaga
Copy link
Contributor Author

anuraaga commented Sep 4, 2020

@zenmoto FYI I've added this logback instrumentation very similar to the log4j instrumentation. Happy to update if there's any semantic changes :)

@anuraaga anuraaga merged commit d21db7b into open-telemetry:master Sep 4, 2020
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.

None yet

2 participants