apache / paimon

Apache Paimon is a lake format that enables building a Realtime Lakehouse Architecture with Flink and Spark for both streaming and batch operations.
https://paimon.apache.org/
Apache License 2.0
2.44k stars 959 forks source link

[arrow] Allocate buffer for MapVector in init #4347

Closed leaves12138 closed 1 month ago

leaves12138 commented 1 month ago

Purpose

Init MapVector before write. If not, export VectorSchemaRoot to c-struct when meet a empty Map will cause an error while deserializing in c++: arrow/cpp/src/arrow/result.cc:28: ValueOrDie called on an error: Invalid: ArrowArrayStruct contains null data pointer for a buffer with non-zero computed size

Tests

API and Format

Documentation

JingsongLi commented 1 month ago

+1