Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tests/routes/categories/get: Avoid database connection deadlock #5614

Merged
merged 1 commit into from
Dec 8, 2022

Conversation

Turbo87
Copy link
Member

@Turbo87 Turbo87 commented Dec 8, 2022

The app.db() closure takes the only existing database connection and any API requests inside the closure can deadlock waiting on the connection. For some reason this does not appear to cause any issues in the current state, but once the API requests are going through an async layer this is starting to cause issues.

@Turbo87 Turbo87 added C-internal 🔧 Category: Nonessential work that would make the codebase more consistent or clear A-backend ⚙️ labels Dec 8, 2022
The `app.db()` closure takes the only existing database connection and any API requests inside the closure can deadlock waiting on the connection. For some reason this does not appear to cause any issues in the current state, but once the API requests are going through an async layer this is starting to cause issues.
@Turbo87 Turbo87 merged commit b123a1e into rust-lang:master Dec 8, 2022
@Turbo87 Turbo87 deleted the db-deadlock branch December 8, 2022 21:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-backend ⚙️ C-internal 🔧 Category: Nonessential work that would make the codebase more consistent or clear
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant