- 
                Notifications
    You must be signed in to change notification settings 
- Fork 1.1k
          Akka.Remote: harden EndpointWriter against serialization failures
          #7923
        
          New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Detailed my changes
| ByteString pdu; | ||
| try | ||
| { | ||
| pdu = _codec.ConstructMessage(send.Recipient.LocalAddressToUse, send.Recipient, | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wrap all concerns related to outbound serialization in an additional try...catch - throw the inner exception inside a new SerializationException since the outer try...catch knows to log those without disassociating.
| LogPossiblyWrappedMessageType(send.Message)); | ||
| return true; | ||
| } | ||
| catch (ArgumentException ex) | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This additional catch is now redundant given the inner try...catch
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Changes
close #7922 - hardens the Akka.Remote
EndpointWriteragainst a larger range of potential serialization failures.Checklist
For significant changes, please ensure that the following have been completed (delete if not relevant):