raghavyadav01 commented on code in PR #19314:
URL: https://github.com/apache/pinot/pull/19314#discussion_r3856531012


##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/index/openstruct/MutableOpenStructIndex.java:
##########
@@ -282,6 +290,13 @@ public DataType getStoredType() {
   @Override
   public void close()
       throws IOException {
+    if (_ignoredKeyDropCount > 0) {

Review Comment:
   Nit: the counter isn't reset after emitting, so a double `close()` would 
double-count the drops; fine given close() is single-shot today, but a 
`_ignoredKeyDropCount = 0` after emit would make it defensive.



##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/index/openstruct/MutableOpenStructIndex.java:
##########
@@ -98,6 +102,10 @@ public void index(int docId, @Nullable Object value) {
     Map<String, Object> map = (Map<String, Object>) value;
     for (Map.Entry<String, Object> entry : map.entrySet()) {
       String key = entry.getKey();
+      if (_config.isIgnoredKey(key)) {

Review Comment:
   Nit: the `isIgnoredKey` check precedes the null-value check, so an ignored 
key with a `null` value is still counted as a drop; realtime and offline agree 
here so metering stays consistent, just flagging the semantic.



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