jtao15 commented on code in PR #16608:
URL: https://github.com/apache/pinot/pull/16608#discussion_r2279835797


##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/io/util/ValueReader.java:
##########
@@ -63,7 +64,7 @@ default byte[] getUnpaddedBytes(int index, int 
numBytesPerValue, byte[] buffer)
    */
   default String getUnpaddedString(int index, int numBytesPerValue, byte[] 
buffer) {
     int length = readUnpaddedBytes(index, numBytesPerValue, buffer);
-    return new String(buffer, 0, length);
+    return new String(buffer, 0, length, StandardCharsets.UTF_8);

Review Comment:
   My understanding is UTF_8 decoding should not force UTF-16 storage, and how 
Java stores it only depends on the characters in the string. 
   <img width="646" height="322" alt="Screenshot 2025-08-15 at 1 27 54 PM" 
src="https://github.com/user-attachments/assets/cbe69490-abc3-4df5-af2b-93f682386e93";
 />
   



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