4 releases (2 breaking)

0.2.0 Nov 5, 2024
0.1.1 Oct 11, 2024
0.1.0 Oct 11, 2024
0.0.0 Aug 2, 2024

#1817 in Database interfaces

Download history 25/week @ 2025-01-01 103/week @ 2025-01-08 137/week @ 2025-01-15 97/week @ 2025-01-22 273/week @ 2025-01-29 143/week @ 2025-02-05 339/week @ 2025-02-12 223/week @ 2025-02-19 220/week @ 2025-02-26 160/week @ 2025-03-05 187/week @ 2025-03-12 137/week @ 2025-03-19 172/week @ 2025-03-26 193/week @ 2025-04-02 156/week @ 2025-04-09

676 downloads per month
Used in 5 crates (3 directly)

Apache-2.0

13KB
160 lines

rusqlite-pool

Crates.io Documentation license Build Status

A minimal connection pool for rusqlite, suitable for async and multi-threaded usage.

Provides connection pools and handles for sync and async usages:

  • ConnectionPool: A fixed-capacity, thread-safe queue of rusqlite::Connections available for usage.
  • ConnectionHandle: A temporary handle to a connection.
  • AsyncConnectionPool: A thin wrapper around ConnectionPool that uses Semaphores for orderly async access to database connections.
  • AsyncConnectionHandle: A thin wrapper around ConnectionHandle that manages the associated SemaphorePermit.

The async counterparts are behind feature tokio.

Dependencies

~28MB
~451K SLoC