xiangfu0 commented on code in PR #18872:
URL: https://github.com/apache/pinot/pull/18872#discussion_r3680148222


##########
pinot-core/src/main/java/org/apache/pinot/core/common/DataFetcher.java:
##########
@@ -416,6 +422,23 @@ void readBigDecimalValues(int[] docIds, int length, 
BigDecimal[] valueBuffer) {
     void readStringValues(int[] docIds, int length, String[] valueBuffer) {
       Tracing.activeRecording().setInputDataType(_storedType, _singleValue);
       ForwardIndexReaderContext readerContext = getReaderContext();
+      // A UUID column is stored as BYTES, so both paths below would render it 
as hex -- the dictionary is a
+      // BytesDictionary whose getStringValue() is toHexString(). Render the 
canonical form here, at the only layer
+      // that still knows the column's logical type, so every 
getStringValuesSV() caller gets it right.
+      if (_dataType == DataType.UUID) {

Review Comment:
   (placeholder-check)



##########
pinot-common/src/main/java/org/apache/pinot/common/request/context/predicate/BaseInPredicate.java:
##########
@@ -155,4 +157,18 @@ public ByteArray[] getBytesValues() {
     }
     return bigDecimalValues;
   }
+
+  public ByteArray[] getUuidValues() {
+    ByteArray[] uuidValues = _uuidValues;
+    if (uuidValues == null) {
+      int numValues = _values.size();
+      uuidValues = new ByteArray[numValues];
+      for (int i = 0; i < numValues; i++) {
+        uuidValues[i] = new ByteArray(UuidUtils.toBytes(_values.get(i)));
+      }
+      _uuidValues = uuidValues;
+    }
+    return uuidValues;
+  }
+

Review Comment:
   Done — removed.
   
   On why CI did not catch it: the rule is `RegexpMultiline: Blank line before 
closing brace` in `config/checkstyle.xml`. I hit it earlier in this PR on two 
`pinot-core` files and fixed those, but this one slipped through my local 
`checkstyle:check` on `pinot-common`. Re-ran it after the fix and it is clean, 
so your local build was right and mine was not reporting it.



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