cloud-fan commented on code in PR #44583:
URL: https://github.com/apache/spark/pull/44583#discussion_r1442467033


##########
core/src/main/scala/org/apache/spark/util/AccumulatorV2.scala:
##########
@@ -114,8 +114,8 @@ abstract class AccumulatorV2[IN, OUT] extends Serializable {
   final private[spark] def isAtDriverSide: Boolean = atDriverSide
 
   /**
-   * Returns if this accumulator is zero value or not. e.g. for a counter 
accumulator, 0 is zero
-   * value; for a list accumulator, Nil is zero value.
+   * Returns false if this accumulator has been updated. Note that this can be 
true even when
+   * the value is a zero value, if the accumulator was updated with a zero 
value.

Review Comment:
   I think the previous comment is fine. Each accumulator can define the 
semantic of zero value by its own.



-- 
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: [email protected]

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