From 0293b1a0cd6deb04d8c4e4e2840e50d6b838e692 Mon Sep 17 00:00:00 2001 From: Thomas Date: Fri, 8 May 2026 16:43:07 -0400 Subject: [PATCH 1/2] chore(ci): centralize CARGO_INCREMENTAL=0 in setup action --- .github/actions/setup/action.yml | 2 ++ .github/workflows/coverage.yml | 1 - .github/workflows/k8s_e2e.yml | 5 ----- .github/workflows/test-make-command.yml | 1 - .github/workflows/unit-tests.yml | 1 - .github/workflows/unit_mac.yml | 2 -- 6 files changed, 2 insertions(+), 10 deletions(-) diff --git a/.github/actions/setup/action.yml b/.github/actions/setup/action.yml index 3c7e645e6831b..4e0ee71078b05 100644 --- a/.github/actions/setup/action.yml +++ b/.github/actions/setup/action.yml @@ -142,6 +142,8 @@ runs: echo "RUST_BACKTRACE=full" >> "$GITHUB_ENV" # Set nice CI colors echo "CARGO_TERM_COLOR=always" >> "$GITHUB_ENV" + # Incremental compilation is useless in CI: no state is shared between runs + echo "CARGO_INCREMENTAL=0" >> "$GITHUB_ENV" fi - name: Enable rust matcher diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index 5af2787d2b90f..a07ec850373a4 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -28,7 +28,6 @@ permissions: contents: read env: - CARGO_INCREMENTAL: "0" # Disable incremental compilation for coverage CI: true jobs: diff --git a/.github/workflows/k8s_e2e.yml b/.github/workflows/k8s_e2e.yml index 53f811f0a2a35..49c725e04fd4e 100644 --- a/.github/workflows/k8s_e2e.yml +++ b/.github/workflows/k8s_e2e.yml @@ -72,10 +72,6 @@ jobs: if: ${{ !failure() && !cancelled() && github.event_name != 'pull_request' && needs.changes.outputs.website_only != 'true' && needs.changes.outputs.k8s != 'false' }} # cargo-deb requires a release build, but we don't need optimizations for tests env: - CARGO_PROFILE_RELEASE_OPT_LEVEL: 0 - CARGO_PROFILE_RELEASE_LTO: thin # fat LTO OOMs/timeouts on standard 16GB runners; thin is sufficient to verify linking - CARGO_PROFILE_RELEASE_CODEGEN_UNITS: 256 - CARGO_INCREMENTAL: 0 DISABLE_MOLD: true steps: - name: Checkout branch @@ -211,7 +207,6 @@ jobs: env: USE_MINIKUBE_CACHE: "true" SKIP_PACKAGE_DEB: "true" - CARGO_INCREMENTAL: 0 HELM_CHART_REPO: ${{ github.workspace }}/helm-charts/charts/vector with: timeout_minutes: 45 diff --git a/.github/workflows/test-make-command.yml b/.github/workflows/test-make-command.yml index 2a93f9016fcd1..b0a5e9aa6b4aa 100644 --- a/.github/workflows/test-make-command.yml +++ b/.github/workflows/test-make-command.yml @@ -37,7 +37,6 @@ jobs: id-token: write timeout-minutes: 90 env: - CARGO_INCREMENTAL: 0 DD_ENV: "ci" steps: - name: Checkout branch diff --git a/.github/workflows/unit-tests.yml b/.github/workflows/unit-tests.yml index 3f95e9262a21f..b6bf76de5f10c 100644 --- a/.github/workflows/unit-tests.yml +++ b/.github/workflows/unit-tests.yml @@ -55,7 +55,6 @@ permissions: contents: read env: - CARGO_INCREMENTAL: "0" CI: true DD_ENV: "ci" diff --git a/.github/workflows/unit_mac.yml b/.github/workflows/unit_mac.yml index a44a84d368953..aec7b4521e26a 100644 --- a/.github/workflows/unit_mac.yml +++ b/.github/workflows/unit_mac.yml @@ -15,8 +15,6 @@ jobs: unit-mac: runs-on: macos-14-xlarge timeout-minutes: 90 - env: - CARGO_INCREMENTAL: 0 steps: - name: Checkout branch uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 From 1ae4faf67bd011659152965bc71f69967fc4592a Mon Sep 17 00:00:00 2001 From: Thomas Date: Fri, 8 May 2026 16:46:09 -0400 Subject: [PATCH 2/2] Update .github/actions/setup/action.yml Co-authored-by: Pavlos Rontidis --- .github/actions/setup/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/setup/action.yml b/.github/actions/setup/action.yml index f049516993951..7257d92a8266b 100644 --- a/.github/actions/setup/action.yml +++ b/.github/actions/setup/action.yml @@ -142,7 +142,7 @@ runs: echo "RUST_BACKTRACE=full" >> "$GITHUB_ENV" # Set nice CI colors echo "CARGO_TERM_COLOR=always" >> "$GITHUB_ENV" - # Incremental compilation is useless in CI: no state is shared between runs + # Incremental compilation has no benefit because in our CI we always start from a clean state. echo "CARGO_INCREMENTAL=0" >> "$GITHUB_ENV" fi