From 05162504e8918e147aa3e470018a878be39d8cbd Mon Sep 17 00:00:00 2001 From: Chris Bono Date: Sun, 1 Oct 2023 22:30:58 -0500 Subject: [PATCH] [CI] Remove log-complete job in ci.yml * Use gradle-build-action in ci-pr.yml * Rename deploy-docs-antora.yml to deploy-docs-dispatcher-antora.yml --- .github/workflows/ci-pr.yml | 23 +++---------------- .github/workflows/ci.yml | 18 ++++----------- ....yml => deploy-docs-dispatcher-antora.yml} | 2 +- 3 files changed, 8 insertions(+), 35 deletions(-) rename .github/workflows/{deploy-docs-antora.yml => deploy-docs-dispatcher-antora.yml} (95%) diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml index a57fd640..22a021ef 100644 --- a/.github/workflows/ci-pr.yml +++ b/.github/workflows/ci-pr.yml @@ -21,34 +21,19 @@ jobs: if: github.repository == 'spring-projects/spring-pulsar' runs-on: ubuntu-latest steps: - - name: Checkout repo - uses: actions/checkout@v3 - - - name: Set up Java 17 - uses: actions/setup-java@v3 + - uses: actions/checkout@v3 + - name: Set up gradle + uses: spring-io/spring-gradle-build-action@v2 with: java-version: 17 distribution: temurin - - - name: Setup Gradle user name - run: | - mkdir -p ~/.gradle - echo 'systemProp.user.name=spring-builds+github' >> ~/.gradle/gradle.properties - - - name: Setup Gradle - uses: gradle/gradle-build-action@v2 - env: - GRADLE_USER_HOME: ~/.gradle - - name: Build and run unit tests run: | ./gradlew clean build -x integrationTest --continue --scan - - name: Create Aggregated Jacoco Report if: contains(github.event.pull_request.labels.*.name, 'ci/upload-jacoco') run: | ./gradlew aggregateJacocoTestReport --info - - name: Upload Aggregated Jacoco Report if: contains(github.event.pull_request.labels.*.name, 'ci/upload-jacoco') uses: actions/upload-artifact@v3 @@ -56,11 +41,9 @@ jobs: name: jacoco-results path: 'build/reports/jacoco/**/*.*' retention-days: 3 - - name: Run integration tests run: | ./gradlew integrationTest --rerun-tasks -DdownloadRabbitConnector=true --scan - - name: Capture Test Results if: failure() uses: actions/upload-artifact@v3 diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0e846db9..5150e5b3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -39,8 +39,8 @@ jobs: # Extract version from gradle.properties version=$(cat gradle.properties | grep "version=" | awk -F'=' '{print $2}') echo "project_version=$version" >>$GITHUB_OUTPUT - build_jdk_17: - name: Build JDK 17 + build_deploy_jdk_17: + name: Build and Deploy Artifacts (JDK 17) needs: [prerequisites] runs-on: ubuntu-latest if: needs.prerequisites.outputs.runjobs @@ -72,10 +72,9 @@ jobs: ORG_GRADLE_PROJECT_signingPassword: ${{ secrets.GPG_PASSPHRASE }} OSSRH_TOKEN_USERNAME: ${{ secrets.OSSRH_S01_TOKEN_USERNAME }} OSSRH_TOKEN_PASSWORD: ${{ secrets.OSSRH_S01_TOKEN_PASSWORD }} - deploy_docs_antora: name: Deploy Antora Docs - needs: [build_jdk_17] + needs: [build_deploy_jdk_17] runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 @@ -100,18 +99,9 @@ jobs: context-root: spring-pulsar cloudflare-zone-id: ${{ secrets.CLOUDFLARE_ZONE_ID }} cloudflare-cache-token: ${{ secrets.CLOUDFLARE_CACHE_TOKEN }} - - log_complete: - name: Log Complete - needs: [prerequisites, build_jdk_17, deploy_docs_antora] - runs-on: ubuntu-latest - steps: - - name: Echo completion message - run: | - echo "All complete!!" perform_release: name: Perform Release - needs: [prerequisites, build_jdk_17, deploy_docs_antora] + needs: [prerequisites, build_deploy_jdk_17, deploy_docs_antora] runs-on: ubuntu-latest permissions: contents: write diff --git a/.github/workflows/deploy-docs-antora.yml b/.github/workflows/deploy-docs-dispatcher-antora.yml similarity index 95% rename from .github/workflows/deploy-docs-antora.yml rename to .github/workflows/deploy-docs-dispatcher-antora.yml index ffb979a4..2f4e64b8 100644 --- a/.github/workflows/deploy-docs-antora.yml +++ b/.github/workflows/deploy-docs-dispatcher-antora.yml @@ -1,4 +1,4 @@ -name: Deploy Docs (Antora) +name: Deploy Docs Dispatcher (Antora) on: # push: # branches-ignore: [ gh-pages ]