spark-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jiangxb1987 <...@git.apache.org>
Subject [GitHub] spark pull request #22165: [SPARK-25017][Core] Add test suite for BarrierCoo...
Date Wed, 26 Sep 2018 14:40:34 GMT
Github user jiangxb1987 commented on a diff in the pull request:

    https://github.com/apache/spark/pull/22165#discussion_r220589416
  
    --- Diff: core/src/main/scala/org/apache/spark/BarrierCoordinator.scala ---
    @@ -187,6 +191,12 @@ private[spark] class BarrierCoordinator(
           requesters.clear()
           cancelTimerTask()
         }
    +
    +    // Check for clearing internal data, visible for test only.
    +    private[spark] def cleanCheck(): Boolean = requesters.isEmpty && timerTask
== null
    +
    +    // Get currently barrier epoch, visible for test only.
    +    private[spark] def getBarrierEpoch(): Int = barrierEpoch
    --- End diff --
    
    Why not just make `barrierEpoch` visible for testing?


---

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


Mime
View raw message