Arm the connection-pool guard in core (in-memory): default warn -> throw
Part of PLAN-018, Unit 5 (core half). Full design: agent-plans PLAN-018.
Flip the in-memory ConnectionPool nested-acquisition guard (added in
PR #1461, warn-mode) so throwing is the DEFAULT — make
assertNoNestedPoolAcquisition throw instead of System.err-warn, keeping
the Start.isTesting-only gating. Update
NestedConnectionAcquisitionGuardTest so the negative case relies on the
new default rather than calling setThrowOnNestedAcquisition(true)
(keep the toggle for any remaining opt-out, and reset it in finally).
Gate — do NOT arm until the suite is green in throw mode. This ticket depends on the three core fixes above (declared) AND, cross-repo (wired by append-cross-deps.sh):
- the pg Unit-3 impl (
pg-impl), because the postgres-backed core tests exercise it, and - the PLAN-017 OAuth-refresh connection-ownership fix — arming before it merges reintroduces a red from that path.
Acceptance.
- Guard throws by default; full sqlite + postgres suites green with it
armed. No
[nested-conn-guard]warnings remain in warn-mode logs before the flip. - CHANGELOG line under the topmost unreleased section:
The nested same-pool connection-acquisition guard now fails fast by default. - No version bump in the PR.
Depends-on: #1462 Depends-on: #1463 Depends-on: #1464 Plan: PLAN-018
Depends-on: supertokens/supertokens-postgresql-plugin#413
Depends-on: supertokens/supertokens-core#1450
Source: supertokens/supertokens-core