Rocket/contrib
Sergio Benitez 327b1ad064 Allow sync drops for 'sync_db_pools' connections.
Prior to this commit, connections from 'sync_db_pools' assumed that they
were being dropped in an async context. This is overwhelmingly the
common case as connections are typically dropped immediately after
request processing. Nothing requires this, however, so holding a
connection beyond the scope of the async context was possible (i.e. by
storing a connection in managed state). Given the connection's `Drop`
impl calls `spawn_blocking`, this resulted in a panic on drop.

This commit resolves the issue by modifying `Drop` so that it calls
`spawn_blocking` only when it is executing inside an async context. If
not, the connection is dropped normally, without `spawn_blocking`.
2024-08-18 20:03:01 -07:00
..
db_pools Update 'sqlx' to 0.8, 'rusqlite' to 0.31. 2024-08-14 18:39:17 -07:00
dyn_templates Update 'handlebars' to 6.0. 2024-07-22 14:09:21 -05:00
sync_db_pools Allow sync drops for 'sync_db_pools' connections. 2024-08-18 20:03:01 -07:00
ws Update 'tokio-tungstenite' to 0.23. 2024-08-16 05:30:45 -07:00