chore: tighten release readiness checks
This commit is contained in:
1 parent
e117813578
commit
c7a0e5d055
3 files changed
+62
-2
No files matched your search
@@ -63,6 +63,38 @@ jobs:
|
|||||||
--locked \
|
--locked \
|
||||||
-- -D warnings
|
-- -D warnings
|
||||||
|
|
||||||
|
- name: Run clippy without default features
|
||||||
|
run: |
|
||||||
|
cargo clippy \
|
||||||
|
--workspace \
|
||||||
|
--all-targets \
|
||||||
|
--no-default-features \
|
||||||
|
--locked \
|
||||||
|
-- -D warnings
|
||||||
|
|
||||||
|
check:
|
||||||
|
name: cargo check
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
timeout-minutes: 20
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
|
||||||
|
with:
|
||||||
|
persist-credentials: false
|
||||||
|
|
||||||
|
- name: Install Rust toolchain
|
||||||
|
uses: actions-rust-lang/setup-rust-toolchain@46268bd060767258de96ed93c1251119784f2ab6 # v1
|
||||||
|
with:
|
||||||
|
cache-key: check
|
||||||
|
|
||||||
|
- name: Run check without default features
|
||||||
|
run: |
|
||||||
|
cargo check \
|
||||||
|
--workspace \
|
||||||
|
--no-default-features \
|
||||||
|
--locked
|
||||||
|
|
||||||
test:
|
test:
|
||||||
name: cargo test
|
name: cargo test
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@@ -87,6 +119,13 @@ jobs:
|
|||||||
--all-features \
|
--all-features \
|
||||||
--locked
|
--locked
|
||||||
|
|
||||||
|
- name: Run tests without default features
|
||||||
|
run: |
|
||||||
|
cargo test \
|
||||||
|
--workspace \
|
||||||
|
--no-default-features \
|
||||||
|
--locked
|
||||||
|
|
||||||
docs:
|
docs:
|
||||||
name: cargo doc
|
name: cargo doc
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|||||||
@@ -84,10 +84,16 @@ irtt-cli <server> --duration 0 --interval 250ms --output machine
|
|||||||
Each line represents one client event and starts with an `event` field, for example:
|
Each line represents one client event and starts with an `event` field, for example:
|
||||||
|
|
||||||
```text
|
```text
|
||||||
event=echo_reply seq=4 logical_seq=4 remote=203.0.113.10:2112 raw_rtt_us=12400 effective_rtt_us=12100 adjusted_rtt_us=12100 server_processing_us=300 dscp=0 ecn=0 kernel_rx_ns=none
|
event=echo_reply seq=4 remote=203.0.113.10:2112 client_send_wall_ns=1760000000000000000 client_receive_wall_ns=1760000000012400000 raw_rtt_us=12400 effective_rtt_us=12100 adjusted_rtt_us=12100 server_receive_wall_ns=1760000000006100000 server_receive_mono_ns=5000006100000 server_send_wall_ns=1760000000006400000 server_send_mono_ns=5000006400000 server_processing_us=300 client_to_server_us=6100 server_to_client_us=6000 server_received_count=5 server_received_window=0x1f dscp=0 ecn=0 kernel_rx_ns=none
|
||||||
```
|
```
|
||||||
|
|
||||||
Consumers should match on `event=...` and read the fields they need. Unknown fields should be ignored.
|
Consumers should match on `event=...` and read the fields they need. Unknown fields should be ignored.
|
||||||
|
RTT fields are reported in microseconds. `raw_rtt_us` is the measured client
|
||||||
|
send-to-receive RTT. `effective_rtt_us` and `adjusted_rtt_us` are signed and may
|
||||||
|
be negative when server processing exceeds the raw RTT or timing correction
|
||||||
|
produces a negative adjusted value. When one-way delay fields are present,
|
||||||
|
`client_to_server_us` and `server_to_client_us` are also signed microseconds and
|
||||||
|
may be negative due to wall-clock skew.
|
||||||
|
|
||||||
For consumers that only need RTT values, use:
|
For consumers that only need RTT values, use:
|
||||||
|
|
||||||
|
|||||||
@@ -894,7 +894,6 @@ mod tests {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(feature = "stats")]
|
|
||||||
fn negative_adjusted_reply_event() -> ClientEvent {
|
fn negative_adjusted_reply_event() -> ClientEvent {
|
||||||
ClientEvent::EchoReply {
|
ClientEvent::EchoReply {
|
||||||
seq: 8,
|
seq: 8,
|
||||||
@@ -1233,6 +1232,22 @@ mod tests {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn human_and_simple_print_negative_effective_rtt() {
|
||||||
|
let event = negative_adjusted_reply_event();
|
||||||
|
|
||||||
|
assert!(format_event(&event, OutputMode::Human)
|
||||||
|
.unwrap()
|
||||||
|
.contains("rtt=-1.5ms"));
|
||||||
|
assert_eq!(
|
||||||
|
format_event(&event, OutputMode::Simple),
|
||||||
|
Some(
|
||||||
|
"reply seq=8 remote=127.0.0.1:2112 rtt_us=-1500 raw_rtt_us=500 server_processing_us=2000"
|
||||||
|
.to_owned()
|
||||||
|
)
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
#[cfg(feature = "stats")]
|
#[cfg(feature = "stats")]
|
||||||
fn streamed_and_summary_rtt_use_signed_effective_policy() {
|
fn streamed_and_summary_rtt_use_signed_effective_policy() {
|
||||||
|
|||||||
Reference in new issue
Block a user