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


##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/realtime/impl/json/MutableJsonIndexImpl.java:
##########
@@ -106,6 +107,9 @@ public void add(String jsonString)
       throws IOException {
     try {
       List<Map<String, String>> flattenedRecords = 
JsonUtils.flatten(jsonString, _jsonIndexConfig);
+      if (flattenedRecords.equals(JsonUtils.SKIPPED_FLATTENED_RECORD)) {

Review Comment:
   ```suggestion
         if (flattenedRecords == JsonUtils.SKIPPED_FLATTENED_RECORD) {
   ```



##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/realtime/impl/json/MutableJsonIndexImpl.java:
##########
@@ -766,6 +770,7 @@ public void close() {
       String tableName = 
SegmentUtils.getTableNameFromSegmentName(_segmentName);
       _serverMetrics.addMeteredTableValue(tableName, _columnName, 
ServerMeter.MUTABLE_JSON_INDEX_MEMORY_USAGE,
           _bytesSize);
+      _serverMetrics.addMeteredTableValue(tableName, _columnName, 
ServerMeter.INVALID_JSON_ROWS, _invalidJsonRows);

Review Comment:
   Should we bump it when detecting it, instead of waiting for segment to close?



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