pub struct DieselRegistry<C: Connection + 'static> { /* private fields */ }
Expand description

A database-backed registry, powered by Diesel.

Implementations

Creates a new DieselRegistry.

Arguments
  • connection_pool: connection pool for the database

Create a new DieselRegistry with write exclusivity enabled.

Write exclusivity is enforced by providing a connection pool that is wrapped in a RwLock. This ensures that there may be only one writer, but many readers.

Arguments
  • connection_pool: read-write lock-guarded connection pool for the database

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Returns an iterator over the nodes in the registry. Read more

Returns the count of nodes in the registry. Read more

Returns the node with the given identity, if it exists in the registry. Read more

Determines whether or not the node exists in the registry. Read more

Adds a new node to the registry. Read more

Replaces an existing node with the same identity. Read more

Deletes a node with the given identity and returns the node if it was in the registry. Read more

Adds a new node to the registry. Read more

Replaces an existing node with the same identity. Read more

Deletes a node with the given identity and returns the node if it was in the registry. Read more

Clone implementation for RwRegistry. The implementation of the Clone trait for Box<RwRegistry> calls this method. Read more

Clone the RwRegistry as a Box<dyn RegistryReader>.

Clone the RwRegistry as a Box<dyn RegistryWriter>.

Clone implementation for RwRegistry. The implementation of the Clone trait for Box<RwRegistry> calls this method. Read more

Clone the RwRegistry as a Box<dyn RegistryReader>.

Clone the RwRegistry as a Box<dyn RegistryWriter>.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Convert self to an expression for Diesel’s query builder. Read more

Convert &self to an expression for Diesel’s query builder. Read more

Should always be Self

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more