-
Notifications
You must be signed in to change notification settings - Fork 39
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
feat: auto-populate metadata of log entries at write() #803
Conversation
change visibility of constants in LoggingImpl and MonitoredResourceUtil to use in tests. resolve warning in BaseSystemTest by removing unused var.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good, just asking you to shorten a write function
builder.setTrace(context.getTraceId()); | ||
} | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This function becomes too bulky and hard to follow - perhaps you can export the part dealing with context
into private function?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will look into it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the trace metadata formatting is moved to a stand-alone method
google-cloud-logging/src/main/java/com/google/cloud/logging/LoggingImpl.java
Show resolved
Hide resolved
move the trace metadata formatting to a standalone method. add comments. add unit tests to validate resource metadata prioritizing when passed as WriteOption. fix Context.Builder.setRequest() when passing null.
Populate empty metadata fields of each log entry on write().
Populate empty metadata fields of each log entry on write().
Populate empty metadata fields of each log entry on write().
…ogs redirection to stdout in JUL handler (#808) Aggregates the following work: - #821 - #812 - #807 - #803 - #798 Fixes #689, #691, #799 and #800 * 🦉 Updates from OwlBot See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Implements auto-population of metadata (resource info, http requests, trace and span ids, source location).
Respects auto-population LoggingOptions configuration and WriteOption flag.