mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2025-08-06 23:27:04 +02:00
MINOR: quic: Implement cubic state trace callback
This callback was left as not implemented. It should at least display the algorithm state, the control congestion window the slow start threshold and the time of the current recovery period. Should be helpful to debug. Must be backported to 2.7.
This commit is contained in:
parent
deb978149a
commit
01314b8b53
@ -288,6 +288,16 @@ static void quic_cc_cubic_event(struct quic_cc *cc, struct quic_cc_event *ev)
|
||||
|
||||
static void quic_cc_cubic_state_trace(struct buffer *buf, const struct quic_cc *cc)
|
||||
{
|
||||
struct quic_path *path;
|
||||
struct cubic *c = quic_cc_priv(cc);
|
||||
|
||||
path = container_of(cc, struct quic_path, cc);
|
||||
chunk_appendf(buf, " state=%s cwnd=%llu ssthresh=%d rpst=%dms",
|
||||
quic_cc_state_str(cc->algo->state),
|
||||
(unsigned long long)path->cwnd,
|
||||
(int)c->ssthresh,
|
||||
!tick_isset(c->recovery_start_time) ? -1 :
|
||||
TICKS_TO_MS(tick_remain(c->recovery_start_time, now_ms)));
|
||||
}
|
||||
|
||||
struct quic_cc_algo quic_cc_algo_cubic = {
|
||||
|
Loading…
Reference in New Issue
Block a user