This is an automated email from the ASF dual-hosted git repository.
ppkarwasz pushed a commit to branch 2.x
in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git
The following commit(s) were added to refs/heads/2.x by this push:
new 04c93c1d33 Split `integration-test` into per-deployment jobs (#4216)
04c93c1d33 is described below
commit 04c93c1d33f7d0fc46fe4f390ea1968e8d93c485
Author: Piotr P. Karwasz <[email protected]>
AuthorDate: Sun Jul 26 07:13:52 2026 +0200
Split `integration-test` into per-deployment jobs (#4216)
Splitting the job into `integration-test-snapshot` and
`integration-test-release` removes the `always()` condition and the
result-based ternaries, since each job now follows exactly one deploy
job and inherits its skip. The snapshot variant also drops
`log4j-repository-url`: `deploy-snapshot` has no `nexus-url` output,
so the value was always empty, which is what the reusable workflow
expects for snapshots.
Assisted-By: Claude Fable 5 <[email protected]>
---
.github/workflows/build.yaml | 22 +++++++++++++++-------
1 file changed, 15 insertions(+), 7 deletions(-)
diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml
index e1e25da768..cf4c8f42d1 100644
--- a/.github/workflows/build.yaml
+++ b/.github/workflows/build.yaml
@@ -101,14 +101,22 @@ jobs:
# Encode the `runs-on` input as JSON array
runs-on: '["ubuntu-latest", "macos-latest"]'
- # Run integration-tests automatically after a snapshot or RC is published
- integration-test:
- needs: [ deploy-snapshot, deploy-release ]
- if: ${{ always() && (needs.deploy-snapshot.result == 'success' ||
needs.deploy-release.result == 'success') }}
- name: "integration-test (${{ needs.deploy-release.result == 'success' &&
needs.deploy-release.outputs.project-version ||
needs.deploy-snapshot.outputs.project-version }})"
+ # Run integration-tests automatically after a snapshot is published
+ integration-test-snapshot:
+ needs: deploy-snapshot
+ uses:
apache/logging-log4j-samples/.github/workflows/integration-test.yaml@main
+ with:
+ log4j-version: ${{ needs.deploy-snapshot.outputs.project-version }}
+ # Use the `main` branch of `logging-log4j-samples`
+ samples-ref: 'refs/heads/main'
+
+ # Run integration-tests automatically after an RC is published
+ integration-test-release:
+ needs: deploy-release
uses:
apache/logging-log4j-samples/.github/workflows/integration-test.yaml@main
with:
- log4j-version: ${{ needs.deploy-release.result == 'success' &&
needs.deploy-release.outputs.project-version ||
needs.deploy-snapshot.outputs.project-version }}
- log4j-repository-url: ${{ needs.deploy-release.result == 'success' &&
needs.deploy-release.outputs.nexus-url ||
needs.deploy-snapshot.outputs.nexus-url }}
+ log4j-version: ${{ needs.deploy-release.outputs.project-version }}
+ # URL of the staging repository
+ log4j-repository-url: ${{ needs.deploy-release.outputs.nexus-url }}
# Use the `main` branch of `logging-log4j-samples`
samples-ref: 'refs/heads/main'