Expand description
HistoryCache — ordered sample storage for reliable writer/reader.
DDSI-RTPS 2.5 §8.4.8. Both sides (writer + reader) hold their own cache instance:
- Writer cache:
CacheChanges stored viawrite(), from which re-sends happen on AckNack request. Removes samples only once all matched readers have confirmed them via AckNack. - Reader cache: received
CacheChanges in SN order, for in-order delivery to the application layer. Can be cleared viaremove_up_toafter delivery.
History QoS (WP 1.4 T3 follow-up): the cache is configured via
HistoryKind — KeepAll (hard-bounded, error on
overflow) vs. KeepLast(depth) (ring buffer, the oldest sample drops
out on overflow). KeepLast is spec-conformant (§8.7.4) and
decouples writer-cache GC from reader-ACKNACK progress — a
stalled reader thereby no longer prevents other
readers from getting further samples (“per-destination queue” model).
Structs§
- Cache
Change - Single cache entry.
- History
Cache - Ordered sample storage.
- History
Cache Snapshot - Plain-old-data snapshot of the
HistoryCachestatistics at a single point in time. Produced byHistoryCacheStats::snapshot; each component is loaded withAcquireordering. - History
Cache Stats - Atomically updated snapshot statistics of a
HistoryCache. - Lock
Free Inner - Inner state of the
LockFreeReadHistoryCache. Handed out byLockFreeReadHistoryCache::snapshotas anArc<LockFreeInner>— readers iterate overchangesdirectly. - Lock
Free Read History Cache HistoryCachevariant with a lock-free read path via RCU/copy-on-write.
Enums§
- Cache
Error - Error variants for cache operations.
- Change
Kind - Kind of a cache entry (DDSI-RTPS §8.2.1.2 / §8.7.2.2.2).
- History
Kind - History-QoS (DDSI-RTPS §8.7.4, Spec Table 17).