haskell-distributed / distributed-process

Cloud Haskell core libraries
http://haskell-distributed.github.io
710 stars 95 forks source link

[NTTCP-2] Network.Transport.TCP may reject incoming connection request #437

Open qnikst opened 9 years ago

qnikst commented 9 years ago

[Imported from JIRA. Reported by Edsko de Vries @edsko) as NTTCP-2 on 2012-09-24 11:35:00] Suppose A and B are connected, but the connection breaks. When A realizes this immediately and sends a new (heavyweight) connection request to B, then it /might/ happen that B has not yet realized that the current connection has broken and will therefore reject the incoming request from A as invalid.

This is low priority because

facundominguez commented 9 years ago

From @facundominguez on June 16, 2015 22:23 Copied from: haskell-distributed/distributed-process#31

This may refer to the same problem we are observing when resolving connection crossing [1].

A can retry for a long time if B doesn't have any stimulus to test the connection health. TCP does not detect connection failures unless B is trying to send something, and moreover, detection won't happen promptly unless the user cares to tweak the tcp user timeout or the amount of retries.

[1] https://cloud-haskell.atlassian.net/browse/NTTCP-9