refactor(client): use SignedDuration for one-way delay to support negative values
Allow one-way delay samples to represent negative values caused by wall-clock skew between client and server. Update CLI output and statistics collection to correctly handle and report these signed durations.
This commit is contained in:
1 parent
0b16ee802d
commit
3b5336a487
7 files changed
+193
-19
No files matched your search
@@ -163,10 +163,10 @@ impl ReplySample {
|
||||
rtt_adjusted_ns: rtt.adjusted.map(signed_duration_ns),
|
||||
send_delay_ns: one_way
|
||||
.and_then(|sample| sample.client_to_server)
|
||||
.map(duration_ns_i128),
|
||||
.map(signed_duration_ns),
|
||||
receive_delay_ns: one_way
|
||||
.and_then(|sample| sample.server_to_client)
|
||||
.map(duration_ns_i128),
|
||||
.map(signed_duration_ns),
|
||||
server_processing_ns: server_timing
|
||||
.and_then(|timing| timing.processing)
|
||||
.map(duration_ns_i128),
|
||||
|
||||
Reference in new issue
Block a user