MCPcopy Create free account
hub / github.com/aws/clock-bound / ClockState

Class ClockState

clock-bound/src/daemon/clock_state.rs:37–45  ·  view source on GitHub ↗

The whole `ClockState` component struct. This encompasses both `ClockAdjust` component which interfaces with the `CLOCK_REALTIME` kernel clock to synchronize it with `ClockBound` estimate of UTC (`ClockBound` clock), and `ClockStateWriter` which manages writing the `ClockErrorBound` to SHM segment for the client to read.

Source from the content-addressed store, hash-verified

35};
36
37const FREE_RUNNING_GRACE_PERIOD: Duration = Duration::from_secs(60);
38
39const CLOCK_ADJUST_SUMMARY_PERIOD_SECS: u64 = 600;
40
41/// The whole `ClockState` component struct.
42/// This encompasses both `ClockAdjust` component which interfaces
43/// with the `CLOCK_REALTIME` kernel clock to synchronize it with `ClockBound` estimate
44/// of UTC (`ClockBound` clock), and `ClockStateWriter` which manages writing
45/// the `ClockErrorBound` to SHM segment for the client to read.
46pub(crate) struct ClockState {
47 state_writer: Box<dyn ClockStateWrite>,
48 clock_adjuster: Box<dyn ClockAdjust>,

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected