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
Tried to use a connection from a child process without reconnecting. You need to reconnect to Redis after forking.
I'm wondering if you'll take a PR and if there is a foreseen issue with doing something like:
ifProcess.pid != @pidreconnectandreturnif@autoreconnectraiseInheritedError,"Tried to use a connection from a child process without reconnecting. " +
"You need to reconnect to Redis after forking."end
So basically, if some configuration is turned on, try to reconnect automatically instead of basing this behavior on the upstream after_fork sequence.
I might be off, but it seems to me that this is how it's done in Dalli, the memcached client:
So this is regarding this exception being thrown:
I'm wondering if you'll take a PR and if there is a foreseen issue with doing something like:
So basically, if some configuration is turned on, try to reconnect automatically instead of basing this behavior on the upstream after_fork sequence.
I might be off, but it seems to me that this is how it's done in Dalli, the memcached client:
https://github.com/mperham/dalli/blob/master/lib/dalli/server.rb#L87
And a similar behavior in the mongo driver (did not spend the time to find the code, here is the spec though..:
And this autoreconnect spec in Mongo
https://github.com/mongodb/mongo-ruby-driver/blob/92963999304db8d933a898f8025edce5795c145c/spec/support/shared/socket.rb#L9
The text was updated successfully, but these errors were encountered: