You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@geode.apache.org by "mcmellawatt (GitHub)" <gi...@apache.org> on 2018/09/22 00:28:18 UTC

[GitHub] [geode] mcmellawatt opened pull request #2504: GEODE-5747: Handling SocketException consistently

Attempting to make handling of EOFException and SocketException consistent.  This exception handling and an Assert were the only differences between readDataSerializable(DataInput) and readDataSerializableFixedID(DataInput), so we refactored that and were able to delete the FixedID version of the method.

It doesn't make sense that we would handle EOFException and SocketException in readDataSerializable(DataInput), but not in readDataSerializableFixedID(DataInput).  Looking back at the history of the original EOFException handling in readDataSerializable(DataInput), it looks like this was a quick patch fix because this exception was seen/unhandled in readDataSerializable(DataInput), but there is no reason the same issue couldn't happen in the readDataSerializableFixedID(DataInput) method as well.

In TCPServer, we were swallowing EOFExceptions, so it makes sense to do the same for SocketExceptions since they can also be caused by the client closing their socket.  This has no functional implications other than we won't log an info (or fatal, depending on if the socket is closed) error message.  We still will loop back around and accept new connections with this change.  A test was added verify this.

Thank you for submitting a contribution to Apache Geode.

In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:

### For all changes:
- [X] Is there a JIRA ticket associated with this PR? Is it referenced in the commit message?

- [X] Has your PR been rebased against the latest commit within the target branch (typically `develop`)?

- [X] Is your initial contribution a single, squashed commit?

- [X] Does `gradlew build` run cleanly?

- [X] Have you written or updated unit tests to verify your changes?

- [X] If adding new dependencies to the code, are these dependencies licensed in a way that is compatible for inclusion under [ASF 2.0](http://www.apache.org/legal/resolved.html#category-a)?

### Note:
Please ensure that once the PR is submitted, you check travis-ci for build issues and
submit an update to your PR as soon as possible. If you need help, please send an
email to dev@geode.apache.org.


[ Full content available at: https://github.com/apache/geode/pull/2504 ]
This message was relayed via gitbox.apache.org for notifications@geode.apache.org

[GitHub] [geode] mcmellawatt closed pull request #2504: GEODE-5747: Handling SocketException consistently

Posted by "mcmellawatt (GitHub)" <gi...@apache.org>.
[ pull request closed by mcmellawatt ]

[ Full content available at: https://github.com/apache/geode/pull/2504 ]
This message was relayed via gitbox.apache.org for notifications@geode.apache.org