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

    https://github.com/apache/spark/pull/11911#discussion_r57135519
  
    --- Diff: core/src/main/scala/org/apache/spark/SparkContext.scala ---
    @@ -1745,10 +1745,11 @@ class SparkContext(config: SparkConf) extends 
Logging with ExecutorAllocationCli
        * has overridden the call site using `setCallSite()`, this will return 
the user's version.
        */
       private[spark] def getCallSite(): CallSite = {
    -    val callSite = Utils.getCallSite()
         CallSite(
    -      
Option(getLocalProperty(CallSite.SHORT_FORM)).getOrElse(callSite.shortForm),
    -      
Option(getLocalProperty(CallSite.LONG_FORM)).getOrElse(callSite.longForm)
    +      Option(getLocalProperty(CallSite.SHORT_FORM))
    --- End diff --
    
    I see your point though now this calls `Utils.getCallSite` twice when 
neither property is set. That might be OK, but I wonder if you can instead 
retrieve both property values, and then proceed to call  `Utils.getCallSite` 
once if either is null.


---
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]

Reply via email to