With async proxy and parse loop the messages can arrive at the tracker out of order. Solve this by having the tracker assume that the conversation is always client -> server.
This doesn't support the server initiated conversations (ie. multiple helloOk responses to a single hello from client), but at the moment there is no support for counting these anyway.
If the server starts to speak on its own the tracker will remain blocked waiting for a client message. In turn this causes the try_send to fail at the proxy level and disable tracking. Proxying will continue to work and this will keep clients happy (ie. otherwise Mongoose would reconnect).
With async proxy and parse loop the messages can arrive at the tracker out of order. Solve this by having the tracker assume that the conversation is always client -> server.
This doesn't support the server initiated conversations (ie. multiple
helloOk
responses to a singlehello
from client), but at the moment there is no support for counting these anyway.If the server starts to speak on its own the tracker will remain blocked waiting for a client message. In turn this causes the
try_send
to fail at the proxy level and disable tracking. Proxying will continue to work and this will keep clients happy (ie. otherwise Mongoose would reconnect).