Skip to main content

snapdir_stores/
lib.rs

1//! snapdir stores library.
2//!
3//! Storage backends for snapdir snapshots plus the store-routing and
4//! external-store shim that implement snapdir's store dispatch:
5//!
6//! - [`FileStore`] — the in-process `file://` backend.
7//! - [`S3Store`] — the native AWS-SDK `s3://` backend (ring rustls).
8//! - [`B2Store`] — the native AWS-SDK `b2://` backend, pointed at Backblaze
9//!   B2's S3-compatible endpoint (wraps [`S3Store`] with a custom endpoint).
10//! - [`GcsStore`] — the native `google-cloud-storage` `gs://` backend
11//!   (ring rustls; ADC credential chain).
12//! - [`router`] — scheme → adapter resolution, including the hardcoded
13//!   `gs://`→`gcs` special case for the Google Cloud Storage adapter.
14//! - [`shim`] ([`ExternalStore`]) — the emit-command shim that dispatches
15//!   third-party `snapdir-<name>-store` binaries via the documented
16//!   `get-manifest-command` / `get-fetch-files-command` / `get-push-command`
17//!   contract.
18
19pub mod b2_store;
20pub mod file_store;
21pub mod gcs_store;
22pub mod router;
23pub mod s3_store;
24pub mod shim;
25
26pub use b2_store::B2Store;
27pub use file_store::FileStore;
28pub use gcs_store::{GcsLocation, GcsStore};
29pub use router::{resolve_adapter, Adapter, RouteError};
30pub use s3_store::{S3Location, S3Store};
31pub use shim::ExternalStore;