There is currently no way to distinguish between the socket being closed and any exception occurring during message processing.
As a temporary measure, I propose to send a SocketClosed exception that must be processed by the user application (as is the case with AssociationReleased and AssociationAborted). In the future, it can be interesting to rewrite parts of the StateMachine and the Transport classes to ensure correct transitions (and true asynchronous operations).
Coverage decreased (-0.04%) to 84.57% when pulling 28f009d1644f4503d3b1376818736401f0987c22 on cguebert:SocketClose into 225ddc37dd5804da3254ccd6eacee40832ed3196 on lamyj:master.
There is currently no way to distinguish between the socket being closed and any exception occurring during message processing. As a temporary measure, I propose to send a SocketClosed exception that must be processed by the user application (as is the case with AssociationReleased and AssociationAborted). In the future, it can be interesting to rewrite parts of the StateMachine and the Transport classes to ensure correct transitions (and true asynchronous operations).
This is a possible solution to #39.