Constellation, Spacedust, Slingshot, UFOs: atproto crates and services for microcosm
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

forgot to add storage.rs now

phil 7c1417e9 a437b994

+18
+18
ufos/src/storage.rs
··· 1 + use crate::{error::StorageError, Cursor, EventBatch}; 2 + use std::path::Path; 3 + 4 + pub trait StorageWhatever<R: StoreReader, W: StoreWriter, C> { // TODO: extract this 5 + fn init( 6 + path: impl AsRef<Path>, 7 + endpoint: String, 8 + force_endpoint: bool, 9 + config: C, 10 + ) -> Result<(R, W, Option<Cursor>), StorageError> where Self: Sized; 11 + } 12 + 13 + pub trait StoreWriter { 14 + fn insert_batch(&mut self, event_batch: EventBatch) -> Result<(), StorageError>; 15 + } 16 + 17 + pub trait StoreReader: Clone { 18 + }