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
- Fixrails#51347
- The tests in this suite are leaky which results in other tests
from other suite from sometimes failing.
The problem is due to modifying some database tables while
a prepared statement on Postgreql already exists. This causes
Postgres to report an error
"cached plan must not change result type".
The order of reproduction is as follow:
- We have more than one connection in the pool (Let's say Conn1 and
Conn2 for the sake of the example)
- A first test runs a query, Conn1 is used, we prepare a statement.
- The leaky test modify some table on Conn2.
- A third test runs a query, Conn1 is used, the query was prepared.
Postgresql reports the "cached plan must not change result type".
This commis fixes that by clearing the statement cache on each
connection.
0 commit comments