wzhfy commented on a change in pull request #29580:
URL: https://github.com/apache/spark/pull/29580#discussion_r483959768



##########
File path: core/src/main/scala/org/apache/spark/rpc/netty/Inbox.scala
##########
@@ -200,6 +200,16 @@ private[netty] class Inbox(val endpointName: String, val 
endpoint: RpcEndpoint)
    * Calls action closure, and calls the endpoint's onError function in the 
case of exceptions.
    */
   private def safelyCall(endpoint: RpcEndpoint)(action: => Unit): Unit = {
+    def dealWithFatalException(fatal: Throwable): Unit = {
+      inbox.synchronized {
+        // Should reduce the number of active threads before throw exception
+        if (numActiveThreads != 0) {

Review comment:
       @cloud-fan that would be better, thanks, fixed




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to