Make sure if a DB Session got created for a request, it stays unique per request #8868

Closed
opened 2025-11-02 08:21:38 -06:00 by GiteaMirror · 0 comments
Owner

Originally created by @6543 on GitHub (Apr 26, 2022).

to prevent deadlocks, etc...:

  • use context for all function calling package model and model itself
  • add func that can extract an open session from context if there is one or open a new one
  • be able to make sure, if db.TxContext() was already opened, a function within the stack does not open a second one again
Originally created by @6543 on GitHub (Apr 26, 2022). to prevent deadlocks, etc...: - [x] use context for all function calling package model and model itself - #19511 - ... - [ ] add func that can extract an open session from context if there is one or open a new one - [ ] be able to make sure, if `db.TxContext()` was already opened, a function within the stack does not open a second one again
GiteaMirror added the type/summary label 2025-11-02 08:21:38 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#8868