You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In a previous effort we implemented a different structure for our logging events, using a protobuf "oneof" for all of the individual sets of structured data. We had to abandon that approach because of very poor performance in Python.
Currently the logging events are structured so that there is a top-level "info" field which contains all of the common fields in each event, such as "msg", "level", "thread", "extra", "category", etc. In addition there are other top-level fields for each piece of structured data in the specific logging event.
After looking at other possible event organizations, we are thinking of switching to a structure with only two top-level fields, "info" and "data", where "data" would have the specific event's structured information.
Implementing this would require us to have two messages for every logging event, possibly a SomeEventDetails and a SomeEvent, where SomeEvent would contain an EventInfo message and the SomeEventDetails message. Or alternatively leave the current names the same and make the containing message something like SomeEventMsg, containing an EventInfo and a SomeEvent object. We will also have to refactor the code in "fire_event' to create the containing message, the EventInfo message, and create the final SomeEvent object.
The text was updated successfully, but these errors were encountered:
github-actionsbot
changed the title
Reorganize structure of logging events to have two top level keys
[CT-1549] Reorganize structure of logging events to have two top level keys
Nov 23, 2022
In a previous effort we implemented a different structure for our logging events, using a protobuf "oneof" for all of the individual sets of structured data. We had to abandon that approach because of very poor performance in Python.
Currently the logging events are structured so that there is a top-level "info" field which contains all of the common fields in each event, such as "msg", "level", "thread", "extra", "category", etc. In addition there are other top-level fields for each piece of structured data in the specific logging event.
After looking at other possible event organizations, we are thinking of switching to a structure with only two top-level fields, "info" and "data", where "data" would have the specific event's structured information.
Implementing this would require us to have two messages for every logging event, possibly a SomeEventDetails and a SomeEvent, where SomeEvent would contain an EventInfo message and the SomeEventDetails message. Or alternatively leave the current names the same and make the containing message something like SomeEventMsg, containing an EventInfo and a SomeEvent object. We will also have to refactor the code in "fire_event' to create the containing message, the EventInfo message, and create the final SomeEvent object.
The text was updated successfully, but these errors were encountered: