You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by "Jackie-Jiang (via GitHub)" <gi...@apache.org> on 2023/06/23 06:27:30 UTC

[GitHub] [pinot] Jackie-Jiang commented on a diff in pull request #10944: Push out-of-order events metrics for full upsert

Jackie-Jiang commented on code in PR #10944:
URL: https://github.com/apache/pinot/pull/10944#discussion_r1239367794


##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/upsert/BasePartitionUpsertMetadataManager.java:
##########
@@ -371,13 +371,15 @@ public GenericRow updateRecord(GenericRow record, RecordInfo recordInfo) {
   protected abstract GenericRow doUpdateRecord(GenericRow record, RecordInfo recordInfo);
 
   protected void handleOutOfOrderEvent(Object currentComparisonValue, Object recordComparisonValue) {
-    _serverMetrics.addMeteredTableValue(_tableNameWithType, ServerMeter.PARTIAL_UPSERT_OUT_OF_ORDER, 1L);
+    boolean isPartialUpsertTable = (_partialUpsertHandler != null);
+    _serverMetrics.addMeteredTableValue(_tableNameWithType,
+        isPartialUpsertTable ? ServerMeter.PARTIAL_UPSERT_OUT_OF_ORDER : ServerMeter.UPSERT_OUT_OF_ORDER, 1L);
     _numOutOfOrderEvents++;
     long currentTimeNs = System.nanoTime();
     if (currentTimeNs - _lastOutOfOrderEventReportTimeNs > OUT_OF_ORDER_EVENT_MIN_REPORT_INTERVAL_NS) {
-      _logger.warn("Skipped {} out-of-order events for partial-upsert table (the last event has current comparison "
-              + "value: {}, record comparison value: {})", _numOutOfOrderEvents, currentComparisonValue,
-          recordComparisonValue);
+      _logger.warn("Skipped {} out-of-order events for {} upsert table {} (the last event has current comparison "
+              + "value: {}, record comparison value: {})", _numOutOfOrderEvents,
+          (isPartialUpsertTable ? "partial" : ""), _tableNameWithType, currentComparisonValue, recordComparisonValue);

Review Comment:
   (minor) Let's put `"partial" : "full"` to be more specific



-- 
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: commits-unsubscribe@pinot.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org