Allow rendering a dict of metadata on logger LogEvents from extra parameter #26043
Labels
area: logging
Related to Logging
area: UI/UX
Related to User Interface and User Experience
type: feature-request
What's the use case?
When logging, it can be convenient to dump a blob of metadata (such as several key->value pairs) with a single logline. This can make it easier to read a simple message of what happened, and separately parse some attributes of that event.
Ideas of implementation
Dagster already supports rendering some key/value attributes on events, but doesn't seem to support them for logs
There could be a well-known key in the logging extra data such as "dagster_log_metadata" which will automatically be displayed in the dagster UI in this format.
Note that displaying all the k8s attributes in the message would be very messy, but the metadata table makes this log much easier to read.
Additional information
I tried digging into the graphql and it seems like
GrapheneLogsCapturedEvent
could be updated to implementGrapheneDisplayableEvent
and support ametadataEntries
field, which it would pull from the log's dictionary. If this seems reasonable, happy to try and help contribute something.Message from the maintainers
Impacted by this issue? Give it a 👍! We factor engagement into prioritization.
The text was updated successfully, but these errors were encountered: