This is an automated email from the ASF dual-hosted git repository.
martinzink pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/nifi-minifi-cpp.git
The following commit(s) were added to refs/heads/main by this push:
new ab9942dee MINIFICPP-2916 Move manifest check CI job under docker build
(#2278)
ab9942dee is described below
commit ab9942dee0206357c5e16a6cf13bb2d09006058d
Author: Gabor Gyimesi <[email protected]>
AuthorDate: Mon Oct 12 13:00:11 2026 +0200
MINIFICPP-2916 Move manifest check CI job under docker build (#2278)
---
...lang_arm_manifest.json => docker_manifest.json} | 0
.github/workflows/ci.yml | 81 +++++++++++++---------
CMakeLists.txt | 5 +-
bootstrap/minifi_option.py | 2 +
docker/Dockerfile | 21 +++++-
minifi_rust/CMakeLists.txt | 2 +
6 files changed, 73 insertions(+), 38 deletions(-)
diff --git a/.github/references/ubuntu_22_04_clang_arm_manifest.json
b/.github/references/docker_manifest.json
similarity index 100%
rename from .github/references/ubuntu_22_04_clang_arm_manifest.json
rename to .github/references/docker_manifest.json
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index ff2699044..c7290845b 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -18,14 +18,14 @@ env:
CONAN_PASSWORD_NIFI_CONAN: ${{ secrets.CONAN_ACCESS_TOKEN }}
DOCKER_CMAKE_FLAGS: -DDOCKER_VERIFY_THREAD=3 -DUSE_SHARED_LIBS=
-DSTRICT_GSL_CHECKS=AUDIT -DCI_BUILD=ON -DENABLE_AWS=ON -DENABLE_KAFKA=ON
-DENABLE_MQTT=ON -DENABLE_AZURE=ON -DENABLE_SQL=ON \
-DENABLE_SPLUNK=ON -DENABLE_GCP=ON -DENABLE_OPC=ON
-DENABLE_PYTHON_SCRIPTING=ON -DENABLE_LUA_SCRIPTING=ON -DENABLE_KUBERNETES=ON
-DENABLE_TEST_PROCESSORS=ON -DENABLE_PROMETHEUS=ON \
- -DENABLE_ELASTICSEARCH=ON -DENABLE_GRAFANA_LOKI=ON -DENABLE_COUCHBASE=ON
-DENABLE_LLAMACPP=ON -DMINIFI_LMDB=ON -DDOCKER_BUILD_ONLY=ON
-DMINIFI_PERFORMANCE_TESTS=ON -DMINIFI_RUST=OFF \
- -DDOCKER_USE_CONAN=ON -DDOCKER_NIFI_CONAN_USER=${{ secrets.CONAN_USERNAME
}} -DDOCKER_NIFI_CONAN_PASSWORD=${{ secrets.CONAN_ACCESS_TOKEN }}
+ -DENABLE_ELASTICSEARCH=ON -DENABLE_GRAFANA_LOKI=ON -DENABLE_COUCHBASE=ON
-DENABLE_LLAMACPP=ON -DMINIFI_LMDB=ON -DDOCKER_BUILD_ONLY=ON
-DMINIFI_PERFORMANCE_TESTS=ON -DMINIFI_RUST=ON \
+ -DENABLE_BUSTACHE=ON -DENABLE_SFTP=ON -DENABLE_EXECUTE_PROCESS=ON
-DDOCKER_USE_CONAN=ON -DDOCKER_NIFI_CONAN_USER=${{ secrets.CONAN_USERNAME }}
-DDOCKER_NIFI_CONAN_PASSWORD=${{ secrets.CONAN_ACCESS_TOKEN }}
jobs:
macos_xcode:
name: "macOS 26 aarch64"
if: >-
- github.event_name != 'push' ||
- github.repository != 'apache/nifi-minifi-cpp' ||
+ github.event_name != 'push' ||
+ github.repository != 'apache/nifi-minifi-cpp' ||
github.ref == 'refs/heads/main'
runs-on: macos-26
timeout-minutes: 240
@@ -140,8 +140,8 @@ jobs:
windows_VS2022:
name: "Windows Server 2025 x86_64"
if: >-
- github.event_name != 'push' ||
- github.repository != 'apache/nifi-minifi-cpp' ||
+ github.event_name != 'push' ||
+ github.repository != 'apache/nifi-minifi-cpp' ||
github.ref == 'refs/heads/main'
runs-on: windows-2025
timeout-minutes: 300
@@ -264,8 +264,8 @@ jobs:
ubuntu_22_04_clang_arm:
name: "Ubuntu 22.04 clang aarch64"
if: >-
- github.event_name != 'push' ||
- github.repository != 'apache/nifi-minifi-cpp' ||
+ github.event_name != 'push' ||
+ github.repository != 'apache/nifi-minifi-cpp' ||
github.ref == 'refs/heads/main'
runs-on: ubuntu-22.04-arm
timeout-minutes: 240
@@ -376,26 +376,6 @@ jobs:
ulimit -c unlimited
ctest --timeout 300 -j$(nproc) --output-on-failure -LE performance
working-directory: build
- - name: Check manifest
- id: check_manifest
- working-directory: build
- run: |
- sed -i
's|nifi\.extension\.path=\.\./extensions/\*|nifi.extension.path=./*|'
conf/minifi.properties
- ./bin/minifi --manifest | diff -u
../.github/references/ubuntu_22_04_clang_arm_manifest.json - > manifest.patch
|| {
- echo "::error::Manifest mismatch! Download the artifact to apply
the patch."
- cat manifest.patch
- exit 1
- }
-
- - name: Upload patch file
- if: failure() && steps.check_manifest.outcome == 'failure'
- uses: actions/upload-artifact@v4
- with:
- name: update-manifest.patch
- path: build/manifest.patch
- if-no-files-found: ignore
- retention-days: 5
-
- name: performance-test
id: performance-test
run: ctest -j1 --verbose -L performance
@@ -439,8 +419,8 @@ jobs:
rocky:
name: "Rocky (docker) x86_64"
if: >-
- github.event_name != 'push' ||
- github.repository != 'apache/nifi-minifi-cpp' ||
+ github.event_name != 'push' ||
+ github.repository != 'apache/nifi-minifi-cpp' ||
github.ref == 'refs/heads/main'
runs-on: ubuntu-24.04
timeout-minutes: 180
@@ -513,8 +493,8 @@ jobs:
docker_build:
name: "Docker build for integration tests (x86_64)"
if: >-
- github.event_name != 'push' ||
- github.repository != 'apache/nifi-minifi-cpp' ||
+ github.event_name != 'push' ||
+ github.repository != 'apache/nifi-minifi-cpp' ||
github.ref == 'refs/heads/main'
runs-on: ubuntu-22.04
timeout-minutes: 180
@@ -662,11 +642,44 @@ jobs:
with:
name: minifi_rs_behave
path: minifi_rust/minifi_rs_behave/output
+ check_manifest:
+ name: "Check manifest"
+ needs: docker_build
+ runs-on: ubuntu-24.04
+ timeout-minutes: 20
+ steps:
+ - id: checkout
+ uses: actions/checkout@v6
+ - name: Download artifact
+ uses: actions/download-artifact@v8
+ with:
+ name: minifi_docker
+ path: build
+ - name: Load Docker image
+ run: |
+ docker load --input ./build/minifi_docker.tar | awk '{print $NF}' |
xargs -I {} docker tag {} apacheminificpp:manifest
+ - name: Check manifest
+ id: check_manifest
+ run: |
+ docker run --rm apacheminificpp:manifest ./bin/minifi --manifest >
.github/references/docker_manifest.json
+ git diff --exit-code -- .github/references/docker_manifest.json >
manifest.patch || {
+ echo "::error::Manifest mismatch! Download the artifact to apply
the patch."
+ cat manifest.patch
+ exit 1
+ }
+ - name: Upload patch file
+ if: failure() && steps.check_manifest.outcome == 'failure'
+ uses: actions/upload-artifact@v4
+ with:
+ name: update-manifest.patch
+ path: manifest.patch
+ if-no-files-found: ignore
+ retention-days: 5
linters:
name: "C++ lint + Shellcheck + Ruff + Cargo fmt check + Clippy check"
if: >-
- github.event_name != 'push' ||
- github.repository != 'apache/nifi-minifi-cpp' ||
+ github.event_name != 'push' ||
+ github.repository != 'apache/nifi-minifi-cpp' ||
github.ref == 'refs/heads/main'
runs-on: ubuntu-24.04-arm
timeout-minutes: 15
diff --git a/CMakeLists.txt b/CMakeLists.txt
index db3dde31d..7e8a35b74 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -347,9 +347,10 @@ else()
list(APPEND MINIFI_CPP_COMPILE_OPTIONS -Werror)
endif()
if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
- if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 15)
+ # False positive in GCC 14: jsoncons/utility/bigint.hpp:299:13: error:
'<anonymous>' may be used uninitialized
+ # Issue in GCC 15 and above
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118634
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 14)
list(APPEND MINIFI_CPP_COMPILE_OPTIONS -Wno-maybe-uninitialized)
- # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118634
endif()
endif()
endif()
diff --git a/bootstrap/minifi_option.py b/bootstrap/minifi_option.py
index c9640c176..22ce91581 100644
--- a/bootstrap/minifi_option.py
+++ b/bootstrap/minifi_option.py
@@ -63,6 +63,8 @@ class MinifiOptions:
self.use_ninja.value = cache_values["USE_NINJA"].value
if "USE_CONAN" in cache_values:
self.use_conan.value = cache_values["USE_CONAN"].value
+ if "CMAKE_BUILD_TYPE" in cache_values:
+ self.build_type.value = cache_values["CMAKE_BUILD_TYPE"].value
minifi_prefixed_extension_options = ["MINIFI_RUST", "MINIFI_LMDB"]
self.bool_options = {
name: cache_value
diff --git a/docker/Dockerfile b/docker/Dockerfile
index bbf3c0a4f..cd593bd3c 100644
--- a/docker/Dockerfile
+++ b/docker/Dockerfile
@@ -56,7 +56,9 @@ RUN apk --no-cache add gcc \
python3 \
py3-pip \
m4 \
- pkgconf
+ pkgconf \
+ curl \
+ clang-dev
ENV USER=minificpp
ENV MINIFI_BASE_DIR=/opt/minifi
@@ -70,13 +72,23 @@ COPY --chown=${USER}:${USER} . ${MINIFI_BASE_DIR}
USER ${USER}
+# Unlike Alpine's patched rust, the rustup musl toolchain links statically by
default. Corrosion always passes --target, so the
+# -crt-static rustflags from minifi_rust/.cargo/config.toml don't reach build
scripts, and bindgen's build script can't dlopen libclang.
+# The rustc wrapper applies the flag to every rustc invocation, including
build scripts.
+RUN if echo "$MINIFI_OPTIONS" | grep -q "MINIFI_RUST=ON"; then \
+ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | \
+ CARGO_HOME=${MINIFI_BASE_DIR}/.cargo
RUSTUP_HOME=${MINIFI_BASE_DIR}/.rustup sh -s -- -y --no-modify-path --profile
minimal && \
+ printf '#!/bin/sh\nexec "$@" -C target-feature=-crt-static\n' >
${MINIFI_BASE_DIR}/.cargo/bin/rustc-no-crt-static && \
+ chmod +x ${MINIFI_BASE_DIR}/.cargo/bin/rustc-no-crt-static; \
+ fi
+
RUN --mount=type=secret,id=nifi_conan_password,mode=0444 if [
"${DOCKER_USE_CONAN}" == "ON" ]; then \
set -e; \
cd ${MINIFI_BASE_DIR}/bootstrap && \
python3 -m venv venv && \
source venv/bin/activate && \
pip install -r requirements.txt && \
- python3 main.py --skip-compiler-install --run-conan-install
--minifi-options="${MINIFI_OPTIONS}" && \
+ python3 main.py --skip-compiler-install --run-conan-install
--minifi-options="${MINIFI_OPTIONS} -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE}" && \
if [ -n "${DOCKER_NIFI_CONAN_USER}" ] && [ -f
/run/secrets/nifi_conan_password ]; then \
conan remote login nifi-conan ${DOCKER_NIFI_CONAN_USER} -p "$(cat
/run/secrets/nifi_conan_password)" || true; \
conan upload "*" -r nifi-conan --confirm || true; \
@@ -87,6 +99,11 @@ RUN mkdir -p ${MINIFI_BASE_DIR}/build
WORKDIR ${MINIFI_BASE_DIR}/build
RUN export PATH=/usr/lib64/ccache/bin${PATH:+:${PATH}} && \
export CCACHE_DIR=${MINIFI_BASE_DIR}/.ccache && \
+ if echo "$MINIFI_OPTIONS" | grep -q "MINIFI_RUST=ON"; then \
+ export CARGO_HOME=${MINIFI_BASE_DIR}/.cargo
RUSTUP_HOME=${MINIFI_BASE_DIR}/.rustup && \
+ export PATH=${CARGO_HOME}/bin${PATH:+:${PATH}} && \
+ export RUSTC_WRAPPER=${CARGO_HOME}/bin/rustc-no-crt-static; \
+ fi && \
if [ "${DOCKER_USE_CONAN}" == "ON" ]; then
CONAN_TOOLCHAIN="-DCMAKE_TOOLCHAIN_FILE=conan_toolchain.cmake"; fi && \
cmake -DSTATIC_BUILD= -DSKIP_TESTS=${DOCKER_SKIP_TESTS}
${CONAN_TOOLCHAIN:-} ${MINIFI_OPTIONS} -DAWS_ENABLE_UNITY_BUILD=OFF
-DCMAKE_BUILD_TYPE="${CMAKE_BUILD_TYPE}" .. && \
make -j "$(nproc)" package && \
diff --git a/minifi_rust/CMakeLists.txt b/minifi_rust/CMakeLists.txt
index 0001679a4..7c18c22cf 100644
--- a/minifi_rust/CMakeLists.txt
+++ b/minifi_rust/CMakeLists.txt
@@ -37,6 +37,8 @@ corrosion_import_crate(MANIFEST_PATH
${CMAKE_CURRENT_SOURCE_DIR}/Cargo.toml)
if (NOT ENABLE_TEST_PROCESSORS)
set_target_properties(cargo-build_minifi_rs_playground PROPERTIES
EXCLUDE_FROM_ALL TRUE)
+elseif (CI_BUILD)
+ register_rust_extension(minifi_rs_playground "RUST PLAYGROUND EXTENSION"
ENABLE_TEST_PROCESSORS "This enables rust processors purely for testing
purposes")
endif()
if (MINIFI_EXTENSION_PGP)