Module connection

Source
Expand description

Types related to database connections

Modules§

statement_cache
Helper types for prepared statement caching

Structs§

AnsiTransactionManager
An implementation of TransactionManager which can be used for backends which use ANSI standard syntax for savepoints such as SQLite and PostgreSQL.
DefaultLoadingMode
The default loading mode provided by a Connection.
InTransactionStatus
Various status fields to track the status of a transaction manager with a started transaction
StrQueryHelper
A helper type that allows printing out str slices
ValidTransactionManagerStatus
Valid transaction status for the manager. Can return the current transaction depth

Enums§

InstrumentationEvent
This enum describes possible connection events that can be handled by an Instrumentation implementation
TransactionDepthChange
Represents a change to apply to the depth of a transaction
TransactionManagerStatus
Status of the transaction manager

Traits§

BoxableConnection
A variant of the Connection trait that is usable with dynamic dispatch
Connection
A connection to a database
ConnectionSealed
This trait restricts who can implement Connection
DebugQuery
A helper trait for opaque query representations which allows to get a Display and Debug representation of the underlying type without exposing type specific details
Instrumentation
A type that provides an connection Instrumentation
LoadConnection
The specific part of a Connection which actually loads data from the database
MultiConnectionHelper
This trait provides helper methods to convert a database lookup type to/from an std::any::Any reference. This is used internally by the #[derive(MultiConnection)] implementation
SimpleConnection
Perform simple operations on a backend.
TransactionManager
Manages the internal transaction state for a connection.
WithMetadataLookup
Describes a connection with an underlying crate::sql_types::TypeMetadata::MetadataLookup

Functions§

get_default_instrumentation
Get an instance of the default Instrumentation
set_default_instrumentation
Set a custom constructor for the default Instrumentation used by new connections