Expand description

BonsaiDb’s networked database implementation.

This crate implements BonsaiDb’s networked database implementation. The Server and CustomServer<Backend> types provide their most common functionality by implementing the StorageConnection.

This crate supports two methods for exposing a BonsaiDb server: QUIC and WebSockets.

QUIC is a new protocol built atop UDP. It is designed to operate more reliably than TCP, and features TLS built-in at the protocol level. WebSockets are an established protocol built atop TCP and HTTP.

Our user’s guide has a section covering setting up and accessing a BonsaiDb server.

Feature Flags

By default, the full feature is enabled. These features are prefixed by server- when being enabled from the omnibus bonsaidb crate.

  • full: Enables all the flags below,
  • acme: Enables automtic certificate acquisition through ACME/LetsEncrypt.
  • cli: Enables the cli module.
  • encryption: Enables at-rest encryption.
  • hyper: Enables convenience functions for upgrading websockets using hyper.
  • instrument: Enables instrumenting with tracing.
  • pem: Enables the ability to install a certificate using the PEM format.
  • websockets: Enables WebSocket support.
  • password-hashing: Enables the ability to use password authentication using Argon2.

Re-exports

pub use bonsaidb_core as core;
pub use bonsaidb_local as local;
pub use fabruic;

Modules

Command-line interface for the server.

Structs

The Automated Certificate Management Environment (ACME) configuration.

A connected database client.

A BonsaiDb server.

A locked reference to associated client data.

Defines a no-op dispatcher for a backend with no custom api.

A connected network peer.

Configuration options for Server

A database belonging to a CustomServer.

A PubSub subscriber for a CustomServer.

Enums

An error that can occur inside of a Backend function.

Controls how a server should handle a connection.

The default permissions to use for all connections to the server.

An error occurred while interacting with a Server.

A Backend with no custom functionality.

TCP ApplicationProtocols that BonsaiDb has some knowledge of.

The ways a client can be connected to the server.

Constants

URI of https://letsencrypt.org/ prod Directory. Certificates aquired from this are trusted by most Browsers.

Traits

A collection of supported protocols for a network service.

Tailors the behavior of a server to your needs.

A trait that can dispatch requests for a CustomApi.

A service that can handle incoming HTTP connections. A convenience implementation of TcpService that is useful is you are only serving HTTP and WebSockets over a service.

A service that can handle incoming TCP connections.

Type Definitions

A BonsaiDb server without a custom backend.