Skip to content

Commit 69aee62

Browse files
committed
iter::Timestamp: document qualities, relation to overflows
1 parent d91f4ed commit 69aee62

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
1515
- `iter::Timestamps`: associate the timestamp data relation (now termed "quality") with a wrapping enum instead.
1616
For example, a previous `Timestamp { offset: 1, data_relation: Sync }` is now represented as `Timestamp::Sync(1)`.
1717
This change greatly encourages the downstream user to handle all timestamp qualities.
18+
- Improved `iter::Timestamps` documentation regarding timestamp quality.
1819

1920
## [v0.7.0] - 2022-01-17
2021

itm/src/iter.rs

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,18 @@ pub struct TimestampedTracePackets {
8181
pub consumed_packets: usize,
8282
}
8383

84-
/// Absolute timestamp with quality description. Also see (Appendix D4.2.4).
84+
/// Timestamp relative to trace clock start with quality
85+
/// descriptions. In order of decreasing quality:
86+
/// - [`Sync`](Timestamp::Sync);
87+
/// - [`UnknownDelay`](Timestamp::UnknownDelay);
88+
/// - [`AssocEventDelay`](Timestamp::AssocEventDelay);
89+
/// - [`UnknownAssocEventDelay`](Timestamp::UnknownAssocEventDelay).
90+
///
91+
/// A decrease in timestamp quality indicates an insufficient
92+
/// exfiltration rate of trace packets. A decrease in timestamp
93+
/// quality may herald an overflow event.
94+
///
95+
/// See also (Appendix D4.2.4).
8596
#[derive(Debug, Clone, PartialEq)]
8697
#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
8798
pub enum Timestamp {

0 commit comments

Comments
 (0)