From 0857da77e6d8b8f456455d2636d7d4e1d97e9547 Mon Sep 17 00:00:00 2001 From: Raz Luvaton <16746759+rluvaton@users.noreply.github.com> Date: Wed, 8 Jan 2025 00:44:08 +0200 Subject: [PATCH 1/2] allow to override Base(Large)RepeatedValueViewVector This is done as different arrow implementation have different default list item field name For example, Rust implementation of Arrow (`arrow-rs`) has default value of `item` (https://github.com/apache/arrow-rs/blob/4f1f6e57c568fae8233ab9da7d7c7acdaea4112a/arrow-schema/src/field.rs#L125). And according to the specification, the name of the list is not required to be a specific string. so to make it easier to use Java Arrow implementation with other implementation of Arrow, I'm making the `DATA_VECTOR_NAME` configurable --- .../arrow/vector/complex/BaseLargeRepeatedValueViewVector.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vector/src/main/java/org/apache/arrow/vector/complex/BaseLargeRepeatedValueViewVector.java b/vector/src/main/java/org/apache/arrow/vector/complex/BaseLargeRepeatedValueViewVector.java index 12edd6557b..b5baed4348 100644 --- a/vector/src/main/java/org/apache/arrow/vector/complex/BaseLargeRepeatedValueViewVector.java +++ b/vector/src/main/java/org/apache/arrow/vector/complex/BaseLargeRepeatedValueViewVector.java @@ -44,7 +44,7 @@ public abstract class BaseLargeRepeatedValueViewVector extends BaseValueVector implements RepeatedValueVector, FieldVector { public static final FieldVector DEFAULT_DATA_VECTOR = ZeroVector.INSTANCE; - public static final String DATA_VECTOR_NAME = "$data$"; + public static String DATA_VECTOR_NAME = "$data$"; public static final byte OFFSET_WIDTH = 8; public static final byte SIZE_WIDTH = 8; From bb9d5b1e5e27074d673ae61b13e16b9eb31e979a Mon Sep 17 00:00:00 2001 From: Raz Luvaton <16746759+rluvaton@users.noreply.github.com> Date: Wed, 8 Jan 2025 00:44:44 +0200 Subject: [PATCH 2/2] Update BaseRepeatedValueViewVector.java --- .../arrow/vector/complex/BaseRepeatedValueViewVector.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vector/src/main/java/org/apache/arrow/vector/complex/BaseRepeatedValueViewVector.java b/vector/src/main/java/org/apache/arrow/vector/complex/BaseRepeatedValueViewVector.java index e6213316b5..d548224bdd 100644 --- a/vector/src/main/java/org/apache/arrow/vector/complex/BaseRepeatedValueViewVector.java +++ b/vector/src/main/java/org/apache/arrow/vector/complex/BaseRepeatedValueViewVector.java @@ -44,7 +44,7 @@ public abstract class BaseRepeatedValueViewVector extends BaseValueVector implements RepeatedValueVector, BaseListVector { public static final FieldVector DEFAULT_DATA_VECTOR = ZeroVector.INSTANCE; - public static final String DATA_VECTOR_NAME = "$data$"; + public static String DATA_VECTOR_NAME = "$data$"; public static final byte OFFSET_WIDTH = 4; public static final byte SIZE_WIDTH = 4;