qlog july id parity update - #2537
Conversation
Aligns the abstract Event class with draft-ietf-quic-qlog-main-schema-14 Section 7, which adds the optional top-level tuple (TupleID) and system_info (SystemInformation) fields.
protocol_types was removed from CommonFields in draft-ietf-quic-qlog-main-schema-10 (event_schemas on Trace/TraceSeq replaces it), and reference_time is an optional field per Section 7.5.
Per draft-ietf-quic-qlog-main-schema-14 Section 9.1, the info, debug and verbose loglevel events have a single required message field and no code field (code remains only on error and warning).
draft-ietf-quic-qlog-quic-events-13 splits the old frames_processed event into three (frames_created, frames_parsed, frames_processed), all with a frames array and an optional packet_numbers array. Also fixes packet_numbers to be an array of packet numbers rather than a scalar.
The trigger enum is now idle_timeout, application, error, version_mismatch, stateless_reset, aborted, unspecified. The clean and handshake_timeout values were removed; quiche maps a graceful (NoError) close to no trigger and a failed handshake to idle_timeout.
quic-events-13 (via #498) renamed the owner field to initiator and makes it a required field.
quic-events-13 defines the packet_received trigger value as keys_available (a packet buffered because it could not previously be decrypted), replacing the incorrect keys_unavailable.
quic-events-13 defines the additional packet_dropped trigger values duplicate and key_unavailable.
Replaces the placeholder CryptoError enum with the string form defined by quic-events-13 (text matching crypto_error_0x1XX).
Renames three ApplicationError variants so their serialized values match h3-events-13: http_frame_unexpected, http_request_incomplete, and http_request_rejected.
h3-events-13 adds the ORIGIN frame (RFC 9412). Adds the Origin variant to Http3Frame with an origin_entries array of Http3OriginEntry.
The h3-events-13 schema removes the top-level length and raw fields from frame_created and frame_parsed. Preserve the byte length quiche logs by relocating it into the frame's own RawInfo.
Reflow the mark_closed match introduced when aligning ConnectionClosedTrigger, which was committed unformatted.
The h3-events-13 schema removes the datagram field from datagram_created and datagram_parsed, leaving quarter_stream_id and the optional raw info.
Add the http namespace from h3-events-13: capsule_created and capsule_parsed events carrying an HttpCapsule (datagram or unknown), wired into EventType, EventData and importance mappings.
Advance the schema URIs to quic-13, http3-13 and loglevel-14, and add the http-13 URI for the newly added Capsule Protocol namespace.
The main schema defines VantagePointFlow as client/server/unknown, excluding network. Use a dedicated enum for the flow field instead of reusing VantagePointType, which allowed the invalid network value.
5213af4 to
930e0e0
Compare
antoniovicente
left a comment
There was a problem hiding this comment.
Sorry for the delays in review. Checked each commit vs the drafts for correctness at the best of my ability, but I can't verify that some recent change to drafts was missed as part of this change.
This does seem like an important change to get the definitions and implementation more consistent with the drafts. It does involve some API changes, but I assume that app code will be updated in a timeline fashion.
| internal_code: None, | ||
| reason: Some("Failed to establish connection".to_string()), | ||
| trigger: Some(qlog::events::quic::ConnectionClosedTrigger::HandshakeTimeout) | ||
| trigger: Some(qlog::events::quic::ConnectionClosedTrigger::IdleTimeout) |
There was a problem hiding this comment.
hmm, I would have thought it would be useful to distinguish between a timeout experienced during the handshake vs post handshake. I assume that there are ways to tell if handshake is completed, in which case the distinction doesn't seem as important.
I do agree that this is consistent with the more recent version of the draft.
| HttpInternalError, | ||
| HttpRequestCancelled, | ||
| HttpIncompleteRequest, | ||
| HttpRequestIncomplete, |
There was a problem hiding this comment.
The order of these doesn't seem to match the order in the draft which makes it harder to verify that the two lists are consistent.
This PR updates the qlog crate and its dependents to have parity with the following drafts:
It is composed of several commits to aid review. Suggest squashing them all into one commit on merge