CreativeSolutionsGroup/student-intermediary-checkin-kiosk

Only reconnect if absolutely necessary

SpBills opened this issue · 0 comments

Right now the heartbeat creates a new connection every single time that it sends.

This is because a REQ socket dies if you try to send another REQ without a REP.

What we would rather do is

  1. Accept a heartbeat on the server
  2. Reply to this heartbeat
  3. On the client side, only reconnect if you don't receive a reply from the server.