Cargo Features

Diesel-async has no features set by default.

[dependencies]
diesel-async = { version = "0.4.1", features = ["mysql", "postgres", "async-connection-wrapper", "r2d2", "bb8", "deadpool", "mobc"] }
mysql = futures-channel, mysql_async, mysql_common, tokio

Enables mysql_backend of diesel

postgres = tokio, tokio-postgres

Enables postgres_backend of diesel and rt of tokio

tokio:

Includes basic task execution capabilities

Affects diesel-async::pg, transaction_builder::TransactionBuilder

async-connection-wrapper

Affects diesel-async::async_connection_wrapper

r2d2

Enables r2d2 of diesel

Affects diesel-async::pooled_connection

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.

futures-channel mysql?
tokio-postgres postgres?
tokio mysql? postgres?

Affects async_connection_wrapper::AsyncConnectionWrapper

mysql_async mysql?

Enables mysql_async >=0.30.0, <0.33

mysql_common mysql?

Enables mysql_common >=0.29.0, <0.31.0

bb8 implicit feature

Enables bb8

bb8:

Full-featured async (tokio-based) connection pool (like r2d2)

Affects pooled_connection::bb8, diesel-async::pooled_connection

deadpool implicit feature

Enables deadpool ^0.9

deadpool:

Dead simple async pool

Affects pooled_connection::deadpool, diesel-async::pooled_connection

mobc implicit feature

Enables mobc

mobc:

A generic connection pool with async/await support

Affects pooled_connection::mobc, diesel-async::pooled_connection