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
This commit was created on GitHub.com and signed with GitHub’s verified signature.
Added: StatementTimeout::transaction($context, $callback) opens a
transaction, runs the callback under the budget and commits (rolls back and
rethrows on error). On PostgreSQL the limit is a SET LOCAL that ends with
the transaction, so a rollback — even after a timeout aborted it — leaves
nothing on the session (#6).
Changed (breaking): on PostgreSQL, within() (and run()) entered outside
a transaction throws LogicException when the callback returns with a
transaction open, instead of silently restoring inside it — a later rollback
undid that restore and the session kept the budget timeout. A callback that
throws keeps its own error. MySQL and MariaDB are unaffected: their session
variables are not transactional (#6).