ankitsultana commented on code in PR #12581:
URL: https://github.com/apache/pinot/pull/12581#discussion_r1516947341


##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/upsert/BasePartitionUpsertMetadataManager.java:
##########
@@ -887,6 +887,12 @@ protected void doTakeSnapshot() {
         ServerGauge.UPSERT_VALID_DOC_ID_SNAPSHOT_COUNT, numImmutableSegments);
     _serverMetrics.setValueOfPartitionGauge(_tableNameWithType, _partitionId,
         ServerGauge.UPSERT_PRIMARY_KEYS_IN_SNAPSHOT_COUNT, 
numPrimaryKeysInSnapshot);
+    int numMissedSegments = numTrackedSegments - numImmutableSegments - 
numConsumingSegments;
+    if (numMissedSegments > 0) {
+      _serverMetrics.setValueOfPartitionGauge(_tableNameWithType, _partitionId,

Review Comment:
   Use a counter instead. Once a gauge is set, it will stay at that value 
unless removed.



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