1
0
Fork 0
mirror of https://github.com/dani-garcia/vaultwarden.git synced 2025-07-16 01:01:08 +00:00

Async/Awaited all db methods

This is a rather large PR which updates the async branch to have all the
database methods as an async fn.

Some iter/map logic needed to be changed to a stream::iter().then(), but
besides that most changes were just adding async/await where needed.
This commit is contained in:
BlackDex 2021-11-16 17:07:55 +01:00 committed by Daniel García
parent 0b7d6bf6df
commit 87e08b9e50
No known key found for this signature in database
GPG key ID: FC8A7D14C3CD543A
34 changed files with 1424 additions and 1198 deletions

View file

@ -30,7 +30,7 @@ pub mod __mysql_schema;
#[path = "schemas/postgresql/schema.rs"]
pub mod __postgresql_schema;
// There changes are based on Rocket 0.5-rc wrapper of Diesel: https://github.com/SergioBenitez/Rocket/blob/v0.5-rc/contrib/sync_db_pools
// These changes are based on Rocket 0.5-rc wrapper of Diesel: https://github.com/SergioBenitez/Rocket/blob/v0.5-rc/contrib/sync_db_pools
// A wrapper around spawn_blocking that propagates panics to the calling code.
pub async fn run_blocking<F, R>(job: F) -> R