You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sometimes I need the pool, to construct other stuff in the application. It would be useful to access the state's internal pool, so that I don't need to have two of the same pool in my app's state. What do you think?
It would be possible to impl FromRef<axum_sqlx_tx::State<DB>> for sqlx::Pool<DB>, meaning a State<PgPool> could be extracted from an axum_sqlx_tx::State<sqlx::Postgres>.
Would that work for your use-case?
If you already needed a separate state struct, you'd have to proxy the FromRef implementation manually.
Sometimes I need the pool, to construct other stuff in the application. It would be useful to access the state's internal pool, so that I don't need to have two of the same pool in my app's state. What do you think?
What I mean is that I don't want to have
And have only the
tx_state
, since it already holds a pool.The text was updated successfully, but these errors were encountered: