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
Whenever debugging my code, I've noticed that the following code block from TcpConnectionPool.js can trigger an infinite "self called" setTimeout loop :
I guess it can occur in edge case situations (maybe due to debugging) when :
the connexion is not yet established whenever the realSend is called first
but it fails to be established after the first Timeout is setup, and thus, the self.connected = true; lamda in the TcpConnectionWrapper will never be triggered, and the loop will goes on forever
Calling the destroy method should raise a flag or a notification, a way or another, that could either break the Timeout loop, or even better, break it AND retry to establish a connection to send the message
Can't imagine (yet ?) a scenario that could trigger this case in production (I.E. without debugging interfering), but I feel like it would be much better been conservative and manage this potential bug anyway.
The text was updated successfully, but these errors were encountered:
Whenever debugging my code, I've noticed that the following code block from
TcpConnectionPool.js
can trigger an infinite "self called"setTimeout
loop :I guess it can occur in edge case situations (maybe due to debugging) when :
realSend
is called firstself.connected = true;
lamda in theTcpConnectionWrapper
will never be triggered, and the loop will goes on foreverCalling the
destroy
method should raise a flag or a notification, a way or another, that could either break the Timeout loop, or even better, break it AND retry to establish a connection to send the messageCan't imagine (yet ?) a scenario that could trigger this case in production (I.E. without debugging interfering), but I feel like it would be much better been conservative and manage this potential bug anyway.
The text was updated successfully, but these errors were encountered: