HappenLee commented on code in PR #66601:
URL: https://github.com/apache/doris/pull/66601#discussion_r3747428375
##########
be/src/exprs/aggregate/aggregate_function_array_agg.h:
##########
@@ -265,15 +268,27 @@ struct AggregateFunctionArrayAggData<T> {
}
void write(BufferWritable& buf) const {
- throw Exception(ErrorCode::NOT_IMPLEMENTED_ERROR, "array_agg not
support write");
+ const auto serialized_bytes =
+ column_type->get_uncompressed_serialized_bytes(*column_data,
be_exec_version);
+ std::string serialized_buffer(serialized_bytes, '\0');
+ const auto* end =
+ column_type->serialize(*column_data, serialized_buffer.data(),
be_exec_version);
+ DORIS_CHECK_LE(end, serialized_buffer.data() + serialized_bytes);
+ serialized_buffer.resize(end - serialized_buffer.data());
+ buf.write_binary(serialized_buffer);
}
void read(BufferReadable& buf) {
- throw Exception(ErrorCode::NOT_IMPLEMENTED_ERROR, "array_agg not
support read");
+ DORIS_CHECK(column_data->empty());
+ std::string serialized_buffer;
+ buf.read_binary(serialized_buffer);
Review Comment:
Fixed in 012fb525044. Complex array_agg now consumes the existing varuint
frame length and deserializes zero-copy from the padded ColumnString backing
buffer, validates exact logical consumption, and advances by the framed length.
This preserves STREAMVBYTE_PADDING and removes the read_binary(std::string&) 1
GiB limit. Added ASAN coverage with 65 nullable Int32 elements to force the
StreamVByte path; AggregateFunctionArrayAggTest.* passes 7/7.
--
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]