Github user vanzin commented on a diff in the pull request:

    https://github.com/apache/spark/pull/16690#discussion_r98297209
  
    --- Diff: core/src/main/scala/org/apache/spark/rpc/RpcEndpointRef.scala ---
    @@ -63,8 +65,48 @@ private[spark] abstract class RpcEndpointRef(conf: 
SparkConf)
       def ask[T: ClassTag](message: Any): Future[T] = ask(message, 
defaultAskTimeout)
     
       /**
    -   * Send a message to the corresponding [[RpcEndpoint]] and get its 
result within a default
    -   * timeout, or throw a SparkException if this fails even after the 
default number of retries.
    +   * Send a message to the corresponding [[RpcEndpoint.receiveAndReply]] 
and get its result within a
    +   * default timeout, throw a SparkException if this fails.
    +   *
    +   * Note: this is a blocking action which may cost a lot of time,  so 
don't call it in a message
    +   * loop of [[RpcEndpoint]].
    +
    +   * @param message the message to send
    +   * @tparam T type of the reply message
    +   * @return the reply message from the corresponding [[RpcEndpoint]]
    +   */
    +  def askWithBlocking[T: ClassTag](message: Any): T = 
askWithBlocking(message, defaultAskTimeout)
    --- End diff --
    
    `askWithBlocking` is a weird name. I'd use `blockingAsk`, or `askSync`.


---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to