Expand description
Pluggable hook traits exposed to embedders.
The five traits in this module compose the public hook surface
that an embedding program plugs into a crate::embed::Server
to override the in-crate defaults: backing datastore, seeds
provider, network transport listener, crypto provider, and
metrics sink.
Every trait is object-safe (Box<dyn Trait> works) and
Send + Sync so the implementor can be shared across tokio
tasks. Async methods return BoxFuture handles to keep the
trait dyn-compatible without depending on the async_trait
crate.
Default implementations ship next to each trait. Re-exports
at the crate::embed root mean a typical embedder writes
use dynomite::embed::SimpleSeedsProvider; without reaching
into nested submodules.
Structs§
- Logging
Metrics Sink - Default metrics sink: emits one
tracing::infoevent per flush. Cheap, dependency-free, and useful in development. - Memcache
Datastore - Default Memcache-fronting datastore.
- Memory
Datastore - In-memory datastore used by examples and integration tests.
- Redis
Datastore - Default Redis-fronting datastore.
- Rust
Crypto Provider - Default crypto provider built on the in-crate
crate::crypto::Crypto(RustCrypto-backed AES + RSA). - Simple
Seeds Provider - Re-exported
crate::seeds::simple::SimpleSeedsProviderwith the embedSeedsProvidertrait already implemented.
Enums§
- Crypto
Provider Error - Errors produced by a
CryptoProvider. - Datastore
Error - Errors produced by a
Datastoreimplementation. - Metrics
Error - Errors produced by a
MetricsSink. - Protocol
- Logical wire protocol exposed by a datastore.
Traits§
- Crypto
Provider - Pluggable AES + RSA provider for the DNODE peer protocol.
- Datastore
- Backing datastore the engine forwards routed requests to.
- Metrics
Sink - Pluggable metrics exporter.
- Seeds
Provider - Pluggable seeds provider.
Type Aliases§
- BoxFuture
- Convenience alias for boxed futures returned by hook traits.
- Datastore
Byte Stream - Type alias for the byte stream returned by
Datastore::list_buckets_streamandDatastore::list_keys_stream. - DnsSeeds
Provider - DNS-resolving seeds provider, re-exported under the embed trait.
- Florida
Seeds Provider - Florida HTTP seeds provider, re-exported under the embed trait.