surrealcs 0.4.4

The SurrealCS client code for SurrealDB
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
//! Defines the messages needed for the recovery process.
use tokio::sync::mpsc;

/// For stashing messages in the cache.
///
/// # Variants
/// * `Put(T)`: Stashes a message in the cache.
/// * `Flush(mpsc::Sender<T>)`: Flushes the cache and sends the messages to the sender.
#[derive(Debug, Clone)]
pub enum CacheMessage<T: Clone> {
	Put(T),
	Flush(mpsc::Sender<T>),
}