Peter Rozsa has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/19507 )

Change subject: IMPALA-11854: ImpalaStringWritable's underlying array can't be 
changed in UDFs
......................................................................


Patch Set 16:

(1 comment)

> Patch Set 14:
>
> (1 comment)

http://gerrit.cloudera.org:8080/#/c/19507/14/fe/src/main/java/org/apache/impala/hive/executor/ImpalaBytesWritable.java
File fe/src/main/java/org/apache/impala/hive/executor/ImpalaBytesWritable.java:

http://gerrit.cloudera.org:8080/#/c/19507/14/fe/src/main/java/org/apache/impala/hive/executor/ImpalaBytesWritable.java@35
PS14, Line 35:     super.set(bytes, 0, bytes.length);
> But if the UDF respects the contract and only uses the buffer in the valid
Yes, if the contract is respected, it would be OK without setCapacity. It's 
more like an assumption that users would expect a ByteWritable, where the 
underlying array matches the input, without any extra bytes, like how it goes 
with Hive.



--
To view, visit http://gerrit.cloudera.org:8080/19507
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ifb28bd0dce7b0482c7abe1f61f245691fcbfe212
Gerrit-Change-Number: 19507
Gerrit-PatchSet: 16
Gerrit-Owner: Peter Rozsa <[email protected]>
Gerrit-Reviewer: Csaba Ringhofer <[email protected]>
Gerrit-Reviewer: Daniel Becker <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Peter Rozsa <[email protected]>
Gerrit-Comment-Date: Mon, 06 Mar 2023 09:17:36 +0000
Gerrit-HasComments: Yes

Reply via email to