This is an automated email from the ASF dual-hosted git repository.

ppkarwasz pushed a commit to branch fix/2.x/split-integration-test
in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git

commit 799759d22c6fb72b6fce6e3e43476b4ce9a7be79
Author: Piotr P. Karwasz <[email protected]>
AuthorDate: Sat Jul 25 09:50:56 2026 +0200

    Split `integration-test` into per-deployment jobs
    
    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 9566bbb255..69593cfdfb 100644
--- a/.github/workflows/build.yaml
+++ b/.github/workflows/build.yaml
@@ -93,14 +93,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'

Reply via email to