You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2022/09/30 19:44:15 UTC

[GitHub] [spark] mridulm commented on pull request #38056: [SPARK-40617] Fix race condition at the handling of ExecutorMetricsPoller's stageTCMP entries

mridulm commented on PR #38056:
URL: https://github.com/apache/spark/pull/38056#issuecomment-1263955083

   Why not something like this:
   
   ```
       stageTCMP.compute((stageId, stageAttemptId), (_, currentCountAndPeaks) =>
         if (null == currentCountAndPeaks) {
           TCMP(new AtomicLong(1), new AtomicLongArray(ExecutorMetricType.numMetrics))
         } else {
           currentCountAndPeaks.count.incrementAndGet()
           currentCountAndPeaks
         })
   ```
   
   in onTaskStart ?


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

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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