Skip to content

Commit f71a02c

Browse files
jbonofrekoulidavidm
authored
GH-898: Upgrade to Apache POM 35 and identify fixes needed to have CI happy (#865)
Closes #898. --------- Co-authored-by: Sutou Kouhei <kou@cozmixng.org> Co-authored-by: Sutou Kouhei <kou@clear-code.com> Co-authored-by: David Li <li.davidm96@gmail.com>
1 parent aee8a10 commit f71a02c

File tree

9 files changed

+48
-174
lines changed

9 files changed

+48
-174
lines changed

.env

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ ARCH_SHORT=amd64
4040

4141
# Default repository to pull and push images from
4242
REPO=ghcr.io/apache/arrow-java-dev
43-
ARROW_REPO=apache/arrow-dev
43+
ARROW_REPO=ghcr.io/apache/arrow-dev
4444

4545
# The setup attempts to generate coredumps by default, in order to disable the
4646
# coredump generation set it to 0
@@ -53,5 +53,4 @@ MAVEN=3.9.9
5353
# Versions for various dependencies used to build artifacts
5454
# Keep in sync with apache/arrow
5555
ARROW_REPO_ROOT=./arrow
56-
PYTHON=3.9
57-
VCPKG="f7423ee180c4b7f40d43402c2feb3859161ef625" # 2024.06.15 Release
56+
VCPKG="4334d8b4c8916018600212ab4dd4bbdc343065d1" # 2025.09.17 Release

.github/workflows/rc.yml

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ jobs:
168168
fail-fast: false
169169
matrix:
170170
platform:
171-
- { runs_on: macos-13, arch: "x86_64"}
171+
- { runs_on: macos-15-intel, arch: "x86_64"}
172172
- { runs_on: macos-14, arch: "aarch_64" }
173173
env:
174174
MACOSX_DEPLOYMENT_TARGET: "14.0"
@@ -222,7 +222,7 @@ jobs:
222222
brew uninstall llvm || :
223223
224224
# We can remove this when we drop support for
225-
# macos-13. because macos-14 or later uses /opt/homebrew/
225+
# macos-15-intel. because macos-14 or later with arm64 uses /opt/homebrew/
226226
# not /usr/local/.
227227
#
228228
# Ensure updating python@XXX with the "--overwrite" option.
@@ -298,7 +298,7 @@ jobs:
298298
fail-fast: false
299299
matrix:
300300
platform:
301-
- runs_on: windows-2019
301+
- runs_on: windows-2022
302302
arch: "x86_64"
303303
steps:
304304
- name: Download source archive
@@ -309,13 +309,19 @@ jobs:
309309
shell: bash
310310
run: |
311311
tar -xf apache-arrow-java-*.tar.gz --strip-components=1
312-
- name: Download the latest Apache Arrow C++
313-
if: github.event_name != 'schedule'
314-
shell: bash
315-
run: |
316-
ci/scripts/download_cpp.sh
312+
# We always use the main branch for apache/arrow for now.
313+
# Because we want to use
314+
# https://github.com/apache/arrow/pull/47749 in
315+
# apache/arrow-java. We can revert this workaround once Apache
316+
# Arrow 22.0.0 that includes the change released.
317+
#
318+
# - name: Download the latest Apache Arrow C++
319+
# if: github.event_name != 'schedule'
320+
# shell: bash
321+
# run: |
322+
# ci/scripts/download_cpp.sh
317323
- name: Checkout Apache Arrow C++
318-
if: github.event_name == 'schedule'
324+
# if: github.event_name == 'schedule'
319325
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
320326
with:
321327
repository: apache/arrow
@@ -354,7 +360,7 @@ jobs:
354360
- name: Build
355361
shell: cmd
356362
run: |
357-
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x64
363+
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" x64
358364
REM For ORC
359365
set TZDIR=/c/msys64/usr/share/zoneinfo
360366
bash -c "ci/scripts/jni_windows_build.sh . arrow build jni"

ci/docker/vcpkg-jni.dockerfile

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -18,24 +18,10 @@
1818
ARG base
1919
FROM ${base}
2020

21-
# Install the libraries required by Gandiva to run
22-
# Use enable llvm[enable-rtti] in the vcpkg.json to avoid link problems in Gandiva
23-
RUN vcpkg install \
24-
--clean-after-build \
25-
--x-install-root=${VCPKG_ROOT}/installed \
26-
--x-manifest-root=/arrow/ci/vcpkg \
27-
--x-feature=dev \
28-
--x-feature=flight \
29-
--x-feature=gcs \
30-
--x-feature=json \
31-
--x-feature=parquet \
32-
--x-feature=gandiva \
33-
--x-feature=s3
34-
3521
# Install Java
3622
# We need Java for JNI headers, but we don't invoke Maven in this build.
3723
ARG java=11
38-
RUN yum install -y java-$java-openjdk-devel && yum clean all
24+
RUN dnf install -y java-$java-openjdk-devel && dnf clean all
3925

4026
# For ci/scripts/{cpp,java}_*.sh
4127
ENV ARROW_HOME=/tmp/local \

ci/scripts/jni_build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ cmake \
6666
-DProtobuf_USE_STATIC_LIBS=ON \
6767
-GNinja \
6868
"${EXTRA_CMAKE_OPTIONS[@]}"
69-
cmake --build "${build_dir}"
69+
cmake --build "${build_dir}" --verbose
7070
if [ "${ARROW_JAVA_BUILD_TESTS}" = "ON" ]; then
7171
ctest \
7272
--output-on-failure \

ci/scripts/jni_macos_build.sh

Lines changed: 10 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -59,72 +59,24 @@ fi
5959

6060
github_actions_group_begin "Building Arrow C++ libraries"
6161
install_dir="${build_dir}/cpp-install"
62-
: "${ARROW_ACERO:=ON}"
63-
export ARROW_ACERO
64-
: "${ARROW_BUILD_TESTS:=OFF}"
65-
export ARROW_BUILD_TESTS
66-
: "${ARROW_DATASET:=ON}"
67-
export ARROW_DATASET
68-
: "${ARROW_GANDIVA:=ON}"
69-
export ARROW_GANDIVA
70-
: "${ARROW_ORC:=ON}"
71-
export ARROW_ORC
72-
: "${ARROW_PARQUET:=ON}"
73-
: "${ARROW_S3:=ON}"
74-
: "${CMAKE_BUILD_TYPE:=Release}"
75-
: "${CMAKE_UNITY_BUILD:=ON}"
7662

77-
export ARROW_TEST_DATA="${arrow_dir}/testing/data"
78-
export PARQUET_TEST_DATA="${arrow_dir}/cpp/submodules/parquet-testing/data"
63+
export ARROW_BUILD_TESTS=OFF
64+
65+
export ARROW_DATASET=ON
66+
export ARROW_GANDIVA=ON
67+
export ARROW_ORC=ON
68+
export ARROW_PARQUET=ON
69+
7970
export AWS_EC2_METADATA_DISABLED=TRUE
8071

8172
cmake \
8273
-S "${arrow_dir}/cpp" \
8374
-B "${build_dir}/cpp" \
84-
-DARROW_ACERO="${ARROW_ACERO}" \
85-
-DARROW_BUILD_SHARED=OFF \
86-
-DARROW_BUILD_TESTS="${ARROW_BUILD_TESTS}" \
87-
-DARROW_CSV="${ARROW_DATASET}" \
88-
-DARROW_DATASET="${ARROW_DATASET}" \
89-
-DARROW_SUBSTRAIT="${ARROW_DATASET}" \
90-
-DARROW_DEPENDENCY_USE_SHARED=OFF \
91-
-DARROW_GANDIVA="${ARROW_GANDIVA}" \
92-
-DARROW_GANDIVA_STATIC_LIBSTDCPP=ON \
93-
-DARROW_JSON="${ARROW_DATASET}" \
94-
-DARROW_ORC="${ARROW_ORC}" \
95-
-DARROW_PARQUET="${ARROW_PARQUET}" \
96-
-DARROW_S3="${ARROW_S3}" \
97-
-DARROW_USE_CCACHE="${ARROW_USE_CCACHE}" \
98-
-DAWSSDK_SOURCE=BUNDLED \
99-
-DCMAKE_BUILD_TYPE="${CMAKE_BUILD_TYPE}" \
100-
-DCMAKE_INSTALL_PREFIX="${install_dir}" \
101-
-DCMAKE_UNITY_BUILD="${CMAKE_UNITY_BUILD}" \
102-
-DGTest_SOURCE=BUNDLED \
103-
-DPARQUET_BUILD_EXAMPLES=OFF \
104-
-DPARQUET_BUILD_EXECUTABLES=OFF \
105-
-DPARQUET_REQUIRE_ENCRYPTION=OFF \
106-
-Dre2_SOURCE=BUNDLED \
107-
-GNinja
75+
--preset=ninja-release-jni-macos \
76+
-DCMAKE_INSTALL_PREFIX="${install_dir}"
10877
cmake --build "${build_dir}/cpp" --target install
10978
github_actions_group_end
11079

111-
if [ "${ARROW_RUN_TESTS:-}" == "ON" ]; then
112-
github_actions_group_begin "Running Arrow C++ libraries tests"
113-
# MinIO is required
114-
exclude_tests="arrow-s3fs-test"
115-
# unstable
116-
exclude_tests="${exclude_tests}|arrow-acero-asof-join-node-test"
117-
exclude_tests="${exclude_tests}|arrow-acero-hash-join-node-test"
118-
ctest \
119-
--exclude-regex "${exclude_tests}" \
120-
--label-regex unittest \
121-
--output-on-failure \
122-
--parallel "$(sysctl -n hw.ncpu)" \
123-
--test-dir "${build_dir}/cpp" \
124-
--timeout 300
125-
github_actions_group_end
126-
fi
127-
12880
export JAVA_JNI_CMAKE_ARGS="-DProtobuf_ROOT=${build_dir}/cpp/protobuf_ep-install"
12981
"${source_dir}/ci/scripts/jni_build.sh" \
13082
"${source_dir}" \
@@ -142,6 +94,7 @@ github_actions_group_begin "Checking shared dependencies for libraries"
14294
pushd "${dist_dir}"
14395
archery linking check-dependencies \
14496
--allow CoreFoundation \
97+
--allow Network \
14598
--allow Security \
14699
--allow libSystem \
147100
--allow libarrow_cdata_jni \

ci/scripts/jni_manylinux_build.sh

Lines changed: 12 additions & 85 deletions
Original file line numberDiff line numberDiff line change
@@ -53,105 +53,32 @@ if [ "${ARROW_USE_CCACHE}" == "ON" ]; then
5353
fi
5454

5555
github_actions_group_begin "Building Arrow C++ libraries"
56-
devtoolset_version="$(rpm -qa "devtoolset-*-gcc" --queryformat '%{VERSION}' | grep -o "^[0-9]*")"
57-
devtoolset_include_cpp="/opt/rh/devtoolset-${devtoolset_version}/root/usr/include/c++/${devtoolset_version}"
58-
: "${ARROW_ACERO:=ON}"
59-
export ARROW_ACERO
60-
: "${ARROW_BUILD_TESTS:=OFF}"
61-
export ARROW_BUILD_TESTS
62-
: "${ARROW_DATASET:=ON}"
63-
export ARROW_DATASET
64-
: "${ARROW_GANDIVA:=ON}"
65-
export ARROW_GANDIVA
66-
: "${ARROW_GCS:=ON}"
67-
: "${ARROW_JEMALLOC:=OFF}"
68-
: "${ARROW_MIMALLOC:=ON}"
69-
: "${ARROW_RPATH_ORIGIN:=ON}"
70-
: "${ARROW_ORC:=ON}"
71-
export ARROW_ORC
72-
: "${ARROW_PARQUET:=ON}"
73-
: "${ARROW_S3:=ON}"
74-
: "${CMAKE_BUILD_TYPE:=release}"
75-
: "${CMAKE_UNITY_BUILD:=ON}"
56+
7657
: "${VCPKG_ROOT:=/opt/vcpkg}"
7758
: "${VCPKG_FEATURE_FLAGS:=-manifests}"
78-
: "${VCPKG_TARGET_TRIPLET:=${VCPKG_DEFAULT_TRIPLET:-x64-linux-static-${CMAKE_BUILD_TYPE}}}"
79-
: "${GANDIVA_CXX_FLAGS:=-isystem;${devtoolset_include_cpp};-isystem;${devtoolset_include_cpp}/x86_64-redhat-linux;-lpthread}"
59+
: "${VCPKG_TARGET_TRIPLET:=${VCPKG_DEFAULT_TRIPLET:-x64-linux-static-release}}"
60+
export VCPKG_TARGET_TRIPLET
61+
62+
export ARROW_BUILD_TESTS=OFF
63+
64+
export ARROW_DATASET=ON
65+
export ARROW_GANDIVA=ON
66+
export ARROW_ORC=ON
67+
export ARROW_PARQUET=ON
8068

81-
export ARROW_TEST_DATA="${arrow_dir}/testing/data"
82-
export PARQUET_TEST_DATA="${arrow_dir}/cpp/submodules/parquet-testing/data"
8369
export AWS_EC2_METADATA_DISABLED=TRUE
8470

8571
install_dir="${build_dir}/cpp-install"
8672

8773
cmake \
8874
-S "${arrow_dir}/cpp" \
8975
-B "${build_dir}/cpp" \
90-
-DARROW_ACERO="${ARROW_ACERO}" \
91-
-DARROW_BUILD_SHARED=OFF \
92-
-DARROW_BUILD_TESTS="${ARROW_BUILD_TESTS}" \
93-
-DARROW_CSV="${ARROW_DATASET}" \
94-
-DARROW_DATASET="${ARROW_DATASET}" \
95-
-DARROW_SUBSTRAIT="${ARROW_DATASET}" \
96-
-DARROW_DEPENDENCY_SOURCE="VCPKG" \
97-
-DARROW_DEPENDENCY_USE_SHARED=OFF \
98-
-DARROW_GANDIVA_PC_CXX_FLAGS="${GANDIVA_CXX_FLAGS}" \
99-
-DARROW_GANDIVA="${ARROW_GANDIVA}" \
100-
-DARROW_GCS="${ARROW_GCS}" \
101-
-DARROW_JEMALLOC="${ARROW_JEMALLOC}" \
102-
-DARROW_JSON="${ARROW_DATASET}" \
103-
-DARROW_MIMALLOC="${ARROW_MIMALLOC}" \
104-
-DARROW_ORC="${ARROW_ORC}" \
105-
-DARROW_PARQUET="${ARROW_PARQUET}" \
106-
-DARROW_RPATH_ORIGIN="${ARROW_RPATH_ORIGIN}" \
107-
-DARROW_S3="${ARROW_S3}" \
108-
-DARROW_USE_CCACHE="${ARROW_USE_CCACHE}" \
109-
-DCMAKE_BUILD_TYPE="${CMAKE_BUILD_TYPE}" \
110-
-DCMAKE_INSTALL_PREFIX="${install_dir}" \
111-
-DCMAKE_UNITY_BUILD="${CMAKE_UNITY_BUILD}" \
112-
-DGTest_SOURCE=BUNDLED \
113-
-DORC_SOURCE=BUNDLED \
114-
-DORC_PROTOBUF_EXECUTABLE="${VCPKG_ROOT}/installed/${VCPKG_TARGET_TRIPLET}/tools/protobuf/protoc" \
115-
-DPARQUET_BUILD_EXAMPLES=OFF \
116-
-DPARQUET_BUILD_EXECUTABLES=OFF \
117-
-DPARQUET_REQUIRE_ENCRYPTION=OFF \
118-
-DVCPKG_MANIFEST_MODE=OFF \
119-
-DVCPKG_TARGET_TRIPLET="${VCPKG_TARGET_TRIPLET}" \
120-
-GNinja
76+
--preset=ninja-release-jni-linux \
77+
-DCMAKE_INSTALL_PREFIX="${install_dir}"
12178
cmake --build "${build_dir}/cpp"
12279
cmake --install "${build_dir}/cpp"
12380
github_actions_group_end
12481

125-
if [ "${ARROW_RUN_TESTS:-OFF}" = "ON" ]; then
126-
github_actions_group_begin "Running Arrow C++ libraries tests"
127-
# MinIO is required
128-
exclude_tests="arrow-s3fs-test"
129-
case $(arch) in
130-
aarch64)
131-
# GCS testbench is crashed on aarch64:
132-
# ImportError: ../grpc/_cython/cygrpc.cpython-38-aarch64-linux-gnu.so:
133-
# undefined symbol: vtable for std::__cxx11::basic_ostringstream<
134-
# char, std::char_traits<char>, std::allocator<char> >
135-
exclude_tests="${exclude_tests}|arrow-gcsfs-test"
136-
;;
137-
esac
138-
# unstable
139-
exclude_tests="${exclude_tests}|arrow-acero-asof-join-node-test"
140-
exclude_tests="${exclude_tests}|arrow-acero-hash-join-node-test"
141-
# external dependency
142-
exclude_tests="${exclude_tests}|arrow-gcsfs-test"
143-
# strptime
144-
exclude_tests="${exclude_tests}|arrow-utility-test"
145-
ctest \
146-
--exclude-regex "${exclude_tests}" \
147-
--label-regex unittest \
148-
--output-on-failure \
149-
--parallel "$(nproc)" \
150-
--test-dir "${build_dir}/cpp" \
151-
--timeout 300
152-
github_actions_group_end
153-
fi
154-
15582
JAVA_JNI_CMAKE_ARGS="-DCMAKE_TOOLCHAIN_FILE=${VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake"
15683
JAVA_JNI_CMAKE_ARGS="${JAVA_JNI_CMAKE_ARGS} -DVCPKG_TARGET_TRIPLET=${VCPKG_TARGET_TRIPLET}"
15784
export JAVA_JNI_CMAKE_ARGS

ci/scripts/jni_windows_build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ cmake \
6868
-B "${build_dir}/cpp" \
6969
-DARROW_ACERO="${ARROW_ACERO}" \
7070
-DARROW_BUILD_SHARED=OFF \
71-
-DARROW_BUILD_TESTS=ON \
71+
-DARROW_BUILD_TESTS="${ARROW_BUILD_TESTS}" \
7272
-DARROW_CSV="${ARROW_DATASET}" \
7373
-DARROW_DATASET="${ARROW_DATASET}" \
7474
-DARROW_SUBSTRAIT="${ARROW_DATASET}" \

compose.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ services:
9999
cache_from:
100100
- ${REPO}:${ARCH}-vcpkg-jni-${VCPKG}
101101
args:
102-
base: ${ARROW_REPO}:${ARCH}-python-${PYTHON}-wheel-manylinux-2014-vcpkg-${VCPKG}
102+
base: ${ARROW_REPO}:${ARCH}-cpp-jni-${VCPKG}
103103
volumes:
104104
- .:/arrow-java:delegated
105105
- ${ARROW_REPO_ROOT}:/arrow:delegated

pom.xml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ under the License.
2323
<parent>
2424
<groupId>org.apache</groupId>
2525
<artifactId>apache</artifactId>
26-
<version>34</version>
26+
<version>35</version>
2727
</parent>
2828

2929
<groupId>org.apache.arrow</groupId>
@@ -91,6 +91,7 @@ under the License.
9191
</issueManagement>
9292

9393
<properties>
94+
<project.build.outputTimestamp>1695310533</project.build.outputTimestamp>
9495
<target.gen.source.path>${project.build.directory}/generated-sources</target.gen.source.path>
9596
<dep.junit.platform.version>1.9.0</dep.junit.platform.version>
9697
<dep.junit.jupiter.version>5.12.2</dep.junit.jupiter.version>
@@ -123,6 +124,8 @@ under the License.
123124
<!--
124125
Downgrade maven-jar-plugin until https://github.com/codehaus-plexus/plexus-archiver/issues/332
125126
is addressed
127+
maven-jar-plugin 4.0.0-beta-2-SNAPSHOT upgraded to plexus-archive 4.10.2 fixing the issue.
128+
We have to wait new maven-jar-plugin release, and a new Apache POM release providing it
126129
-->
127130
<version.maven-jar-plugin>3.2.2</version.maven-jar-plugin>
128131
</properties>

0 commit comments

Comments
 (0)