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
Hello, Thank you for your help the other day.
By the way, I'm facing another problem recently.
In my application, sometimes the server hangs up and stops responding from then on.
I debugged it and found that it occurs in the auto-reconnect process of deno-redis.
When an error raised in processCommandQueue, it tries to reconnect to the server by backing off.
In that case, the call stack would be
sendCommand ...(1)
--> processCommandQueue
(some error raised in command.execeute)
--> connect
--> #connect
--> authenticate or selectDb
--> sendCommand ...(2)
On sendCommand ...(1), the command is pushed to the queue and processCommandQueue is executed.
But in sendCommand ...(2), the command is pushed, but processCommandQueue is not called this time.
The promise of sendCommand ...(2) never resolves and it's the same for all other subsequent sendCommand invocations.
Hello, Thank you for your help the other day.
By the way, I'm facing another problem recently.
In my application, sometimes the server hangs up and stops responding from then on.
I debugged it and found that it occurs in the auto-reconnect process of deno-redis.
I identified this part causes the problem.
https://github.com/denodrivers/redis/blob/28ead060aa467c1558b82b253c0f2f3f9bf10f40/connection.ts#L216C1-L221C10
When an error raised in
processCommandQueue
, it tries to reconnect to the server by backing off.In that case, the call stack would be
On
sendCommand
...(1), the command is pushed to the queue andprocessCommandQueue
is executed.But in
sendCommand
...(2), the command is pushed, butprocessCommandQueue
is not called this time.The promise of
sendCommand
...(2) never resolves and it's the same for all other subsequentsendCommand
invocations.I wrote a test to reproduce this.
yahiro07@347acb3
This occurs when
db
orpassword
is specified in a connection option.I think #318 might be related to this, but I'm not sure since it's reported before the auto reconnect feature was added (#349)
Althought I'm not sure I could do it, I'd like to give it a try to fix this.
Thanks,
yahiro
The text was updated successfully, but these errors were encountered: