-
Notifications
You must be signed in to change notification settings - Fork 593
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
Feature: offline_log_viewer updates #6233
Feature: offline_log_viewer updates #6233
Conversation
…header.type instead of batch.type)
…er.read_envelope to accept a type_read Callable[rdr: Reader, version: Int]: Dict and a max_version parameter. If a type_read is used, it is invoked with reader and envelope if envelope.version <= max_version parameter. the result is joined with a dict {'envelope': envelope} and returned, otherwise an error dict is returned. If no type_read is used, envelope is returned immediately
263c60d
to
885238d
Compare
the new code tries to mimic the structure of the adl decoding functions. the new code is aware of the version number embedded in the binary stream and will skip the field if the version is not supported, while reporting the error.
…update_command) and decode_node_management_command
…rocessed in case of unread byte, an 'unread': {'k': ..., 'v': ...} field is added and an error is logged this check is not exact but is a good proxy to know if the decoding code is correct
…r.skip() for unused fields
885238d
to
a5de788
Compare
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 code in this PR generally looks good, but it's tough to know if we are causing any issues. Can we wire the log viewer into a ducktape test so that as we make changes we are getting automated tests?
(didn't review the code but I notice the commit messages aren't in the usual format: see CONTRIBUTING.md in the source and/or take a peek at the commit history) |
@andijcr this has been stalled for a while -- it's not our top priority, but it would be good to know if there were issues blocking this |
I've merged this into #5315 |
Cover letter
These changes add a first support in tools/offlile_log_viewer for serde-encoded controller messages.
running
will decode logs produced by v22.2 and earlier. serde commands start with a field 'envelope' that contains
[version, compat_version, encoded_size]
.Partially fixes #5293,
implements:
open questions:
Backport Required
UX changes
messages are decoded in a stream of json files. the schema for adl encoded files is unchanged, but the schema for serde - encoded message is different in some places than the corresponding adl-one, reflecting more the hierarchical data organization.
Release notes