liminal-server 0.24.1

Standalone server for the liminal messaging bus
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
//! Monotonic proof that this operation submitted a durable write.

use std::sync::atomic::{AtomicBool, Ordering};

#[derive(Debug, Default)]
pub(super) struct WriteIssuance {
    submitted: AtomicBool,
}

impl WriteIssuance {
    pub(super) fn mark_submitted(&self) {
        self.submitted.store(true, Ordering::Relaxed);
    }

    pub(super) fn was_submitted(&self) -> bool {
        self.submitted.load(Ordering::Relaxed)
    }
}