Skip to content

Commit

Permalink
emit payload and the wrote_all flag as part of the stream_send probe
Browse files Browse the repository at this point in the history
  • Loading branch information
kazuho committed Jan 29, 2025
1 parent 91542af commit f66446b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions lib/quicly.c
Original file line number Diff line number Diff line change
Expand Up @@ -4361,12 +4361,13 @@ quicly_error_t quicly_send_stream(quicly_stream_t *stream, quicly_send_context_t
if (off < stream->sendstate.size_inflight)
stream->conn->super.stats.num_bytes.stream_data_resent +=
(stream->sendstate.size_inflight < off + len ? stream->sendstate.size_inflight : off + len) - off;
QUICLY_PROBE(STREAM_SEND, stream->conn, stream->conn->stash.now, stream, off, len, is_fin);
QUICLY_PROBE(STREAM_SEND, stream->conn, stream->conn->stash.now, stream, off, s->dst - len, len, is_fin, wrote_all);
QUICLY_LOG_CONN(stream_send, stream->conn, {
PTLS_LOG_ELEMENT_SIGNED(stream_id, stream->stream_id);
PTLS_LOG_ELEMENT_UNSIGNED(off, off);
PTLS_LOG_ELEMENT_UNSIGNED(len, len);
PTLS_LOG_APPDATA_ELEMENT_HEXDUMP(data, s->dst - len, len);
PTLS_LOG_ELEMENT_BOOL(is_fin, is_fin);
PTLS_LOG_ELEMENT_BOOL(wrote_all, wrote_all);
});

QUICLY_PROBE(QUICTRACE_SEND_STREAM, stream->conn, stream->conn->stash.now, stream, off, len, is_fin);
Expand Down
4 changes: 2 additions & 2 deletions quicly-probes.d
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,8 @@ provider quicly {
probe application_close_send(struct st_quicly_conn_t *conn, int64_t at, uint64_t error_code, const char *reason_phrase);
probe application_close_receive(struct st_quicly_conn_t *conn, int64_t at, uint64_t error_code, const char *reason_phrase);

probe stream_send(struct st_quicly_conn_t *conn, int64_t at, struct st_quicly_stream_t *stream, uint64_t off, size_t len,
int is_fin);
probe stream_send(struct st_quicly_conn_t *conn, int64_t at, struct st_quicly_stream_t *stream, uint64_t off, const void *data,
size_t data_len, int is_fin, int wrote_all);
probe stream_receive(struct st_quicly_conn_t *conn, int64_t at, struct st_quicly_stream_t *stream, uint64_t off, size_t len);
probe stream_acked(struct st_quicly_conn_t *conn, int64_t at, int64_t stream_id, uint64_t off, size_t len);
probe stream_lost(struct st_quicly_conn_t *conn, int64_t at, int64_t stream_id, uint64_t off, size_t len);
Expand Down

0 comments on commit f66446b

Please sign in to comment.