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

Method disruption_marker

clock-bound/src/client.rs:218–226  ·  view source on GitHub ↗

Take a snapshot of the VMClock shared memory segment and extract the disruption marker. Note that None is returned if no SHM reader is present. # Errors Returns a [`ShmError`] if the content of the segment is uninitialized, unparseable, or otherwise malformed.

(&mut self)

Source from the content-addressed store, hash-verified

216 /// Returns a [`ShmError`] if the content of the segment is uninitialized, unparseable, or
217 /// otherwise malformed.
218 fn disruption_marker(&mut self) -> Result<Option<u64>, ShmError> {
219 if let Some(ref mut vmclock_shm_reader) = self.vmclock_shm_reader {
220 let snap = vmclock_shm_reader.snapshot()?;
221 return Ok(Some(snap.disruption_marker));
222 }
223
224 // The clock disruption support is not enabled
225 Ok(None)
226 }
227}
228
229#[derive(Debug)]

Calls 1

snapshotMethod · 0.45