-
- Downloads
[SPARK-7835] Refactor HeartbeatReceiverSuite for coverage + cleanup
The existing test suite has a lot of duplicate code and doesn't even cover the most fundamental feature of the HeartbeatReceiver, which is expiring hosts that have not responded in a while. This introduces manual clocks in `HeartbeatReceiver` and makes it respond to heartbeats only for registered executors. A few internal messages are moved to `receiveAndReply` to increase determinism of the tests so we don't have to rely on flaky constructs like `eventually`. Author: Andrew Or <andrew@databricks.com> Closes #7173 from andrewor14/heartbeat-receiver-tests and squashes the following commits: 4a903d6 [Andrew Or] Increase HeartReceiverSuite coverage and clean up
Showing
- core/src/main/scala/org/apache/spark/HeartbeatReceiver.scala 69 additions, 20 deletionscore/src/main/scala/org/apache/spark/HeartbeatReceiver.scala
- core/src/main/scala/org/apache/spark/SparkContext.scala 1 addition, 1 deletioncore/src/main/scala/org/apache/spark/SparkContext.scala
- core/src/test/scala/org/apache/spark/HeartbeatReceiverSuite.scala 121 additions, 40 deletions.../test/scala/org/apache/spark/HeartbeatReceiverSuite.scala
Loading
Please register or sign in to comment