dmerkushov / nanoservices

Apache License 2.0
3 stars 0 forks source link

Infinite loop when responding to a dead requester #3

Open a-petelin opened 4 years ago

a-petelin commented 4 years ago

When subscriber dies before receiving response, function writeBin goes into infinite loop

a-petelin commented 4 years ago

This situation happens when the service processes the incoming request for a long time and when it required to send the response the service which sent the request has already died.

dmerkushov commented 4 years ago

Upon a direct conversation with @a-petelin, the following is the way to reproduce:

  1. A sends a request to B
  2. B starts processing the request, the processing is time-consuming
  3. A dies
  4. B finishes processing, tries to send a response, but falls into an infinite loop in writeBin

To be fixed in #4