-
-
Notifications
You must be signed in to change notification settings - Fork 666
Open
Description
Per comment on #925 (comment)
This library does not reset the state of a connection returned to the pool before it is reused.
This means if any operation mutates state of the connection such as session level variables/isolation level, or begins a transaction without committing or rolling back, the new connection request is given a dirty connection object.
This can lead to rather extreme bugs.
to resolve this, the library needs to follow the industry standard practice of issuing a connection.changeUser() with the same user the connection was opened with, ensuring that the state is all reset.
I would suggest doing this on connection release rather than connection acquire so that obtaining a connection can be faster.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels