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
--| Atomically perform an action with the database handle, if there is one.withConnection::Connection-> (PQ.Connection->IOa) ->IOa
withConnection Connection{..} m =do
withMVar connectionHandle $\conn ->doifPQ.isNullConnection conn
then throwIO disconnectedError
else m conn
I'd like to know if there are common ways to automatically reconnect upon such an exception.
Should I do something like use a try-catch at the db pool level?
The text was updated successfully, but these errors were encountered:
@phadej do you know if there is some kind of hook I can use? I'm having a hard time determining the real cause of this but I could find some kind of workaround for the time being.
When inserting batches of data, I'm very often getting hit by
This comes from how
withConnection
is defined:I'd like to know if there are common ways to automatically reconnect upon such an exception.
Should I do something like use a try-catch at the db pool level?
The text was updated successfully, but these errors were encountered: