AntiPattern
Resource Lifetime Mismanagement
resource-lifetime-mismanagement
A recurring resource-lifecycle mismatch where shared long-lived objects (DB engine/sessions, websocket connections) are created or disposed in the wrong layer, leading to premature closure, unawaited coroutines, and flaky test behavior.