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
Our app opens a cursor which can run for hours at a time.
On the longer runs (7+ hours) the cursor occasionally errors out with:
ActiveRecord::StatementInvalid
PG::ConnectionBad: PQsocket() can't get socket descriptor: ROLLBACK
I am trying to rule this gem out as the culprit. I'm not sure if this is masking a different error.
Should we be passing with_hold: true in the options?
After some investigations, seems like the issue in our case is related to the query being run against replica postgresql server, fixed by setting this 2 config lines in postgresql.conf:
Our app opens a cursor which can run for hours at a time.
On the longer runs (7+ hours) the cursor occasionally errors out with:
I am trying to rule this gem out as the culprit. I'm not sure if this is masking a different error.
Should we be passing
with_hold: true
in the options?Here is a snippet of the cursor loop:
Couple things that may or may not be pertinent:
#each_instance
The text was updated successfully, but these errors were encountered: