Github user vanzin commented on a diff in the pull request:
https://github.com/apache/spark/pull/2019#discussion_r16733264
--- Diff:
core/src/main/scala/org/apache/spark/network/ConnectionManager.scala ---
@@ -280,42 +280,46 @@ private[spark] class ConnectionManager(
}
while(!keyInterestChangeRequests.isEmpty) {
+ // Expect key interested in OP_ACCEPT is not change its interest
val (key, ops) = keyInterestChangeRequests.dequeue()
-
try {
- if (key.isValid) {
+ key.synchronized {
--- End diff --
It is normal. In a distributed system, hosts will go down and you have to
handle that.
Now, about logging that it happened. It's useful to log that a host went
down. But is this the place to do it? These exceptions are too generic for that
- CancelledKeyExceptions can happen for other reasons too. So the code that is
notified that a host went down and didn't expect that to happen should log it
instead.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]