feat: remove vendored aws-lambda-cpp dependency #298
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # This workflow will be triggered if there will be changes to | |
| # aws-lambda-java-runtime-interface-client package or its dependencies (core, serialization), | |
| # and it builds the package. | |
| name: PR to runtime-interface-client | |
| on: | |
| workflow_dispatch: | |
| pull_request: | |
| branches: [ '*' ] | |
| paths: | |
| - 'aws-lambda-java-runtime-interface-client/**' | |
| - 'aws-lambda-java-core/**' | |
| - 'aws-lambda-java-serialization/**' | |
| - '.github/workflows/runtime-interface-client_*.yml' | |
| permissions: | |
| contents: read | |
| jobs: | |
| smoke-test-arch: | |
| strategy: | |
| fail-fast: true | |
| matrix: | |
| include: | |
| - arch: x86_64 | |
| runner: ubuntu-latest | |
| - arch: aarch64 | |
| runner: ubuntu-24.04-arm | |
| runs-on: ${{ matrix.runner }} | |
| name: "smoke-test (${{ matrix.arch }})" | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 | |
| - name: Set up JDK 1.8 | |
| uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5 | |
| with: | |
| java-version: 8 | |
| distribution: corretto | |
| cache: maven | |
| - name: Build and install core dependency locally | |
| working-directory: ./aws-lambda-java-core | |
| run: mvn clean install | |
| - name: Build and install serialization dependency locally | |
| working-directory: ./aws-lambda-java-serialization | |
| run: mvn clean install | |
| - name: Runtime Interface Client smoke tests - Run 'pr-${{ matrix.arch }}' target | |
| working-directory: ./aws-lambda-java-runtime-interface-client | |
| run: make pr-${{ matrix.arch }} | |
| env: | |
| IS_JAVA_8: true | |
| build-arch: | |
| strategy: | |
| fail-fast: true | |
| matrix: | |
| include: | |
| - arch: x86_64 | |
| runner: ubuntu-latest | |
| - arch: aarch64 | |
| runner: ubuntu-24.04-arm | |
| runs-on: ${{ matrix.runner }} | |
| name: "build (${{ matrix.arch }})" | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 | |
| - name: Set up JDK 1.8 | |
| uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5 | |
| with: | |
| java-version: 8 | |
| distribution: corretto | |
| cache: maven | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@8d2750c68a42422c14e847fe6c8ac0403b4cbd6f # v3 | |
| with: | |
| install: true | |
| - name: Build and install core dependency locally | |
| working-directory: ./aws-lambda-java-core | |
| run: mvn clean install | |
| - name: Build and install serialization dependency locally | |
| working-directory: ./aws-lambda-java-serialization | |
| run: mvn clean install | |
| - name: Test Runtime Interface Client build - Run 'build-${{ matrix.arch }}' target | |
| working-directory: ./aws-lambda-java-runtime-interface-client | |
| run: make build-${{ matrix.arch }} | |
| env: | |
| IS_JAVA_8: true | |
| - name: Save the built jar | |
| uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 | |
| with: | |
| name: aws-lambda-java-runtime-interface-client-${{ matrix.arch }} | |
| path: ./aws-lambda-java-runtime-interface-client/target/aws-lambda-java-runtime-interface-client-*.jar | |
| - name: Upload coverage to Codecov | |
| if: env.CODECOV_TOKEN != null | |
| uses: codecov/codecov-action@75cd11691c0faa626561e295848008c8a7dddffe # v5 | |
| env: | |
| CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | |
| integration-test-matrix: | |
| runs-on: ${{ matrix.arch.runner }} | |
| strategy: | |
| # Run every OS/arch combination to completion so one failure doesn't mask the others. | |
| fail-fast: false | |
| matrix: | |
| buildspec: | |
| - buildspec.os.alpine.yml | |
| - buildspec.os.amazoncorretto.yml | |
| - buildspec.os.amazonlinux.1.yml | |
| - buildspec.os.amazonlinux.2.yml | |
| - buildspec.os.debian.yml | |
| - buildspec.os.ubuntu.yml | |
| arch: | |
| - label: x64 | |
| runner: ubuntu-latest | |
| platform: linux/amd64 | |
| - label: arm64 | |
| runner: ubuntu-24.04-arm | |
| platform: linux/arm64/v8 | |
| exclude: | |
| # Amazon Linux 1 was never published for ARM64 (x86_64 only), so | |
| # public.ecr.aws/amazonlinux/amazonlinux:1 has no arm64 manifest. | |
| - buildspec: buildspec.os.amazonlinux.1.yml | |
| arch: | |
| label: arm64 | |
| runner: ubuntu-24.04-arm | |
| platform: linux/arm64/v8 | |
| name: "integration-test (${{ matrix.buildspec }} / ${{ matrix.arch.label }})" | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@8d2750c68a42422c14e847fe6c8ac0403b4cbd6f # v3 | |
| with: | |
| install: true | |
| - name: Run OS integration test - 'test-integ' target | |
| working-directory: ./aws-lambda-java-runtime-interface-client | |
| run: make test-integ BUILDSPEC=test/integration/codebuild/${{ matrix.buildspec }} | |
| env: | |
| PLATFORM_FILTER: ${{ matrix.arch.platform }} | |
| integration-test: | |
| needs: integration-test-matrix | |
| if: always() | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check integration-test results | |
| run: | | |
| if [ "${{ needs.integration-test-matrix.result }}" != "success" ]; then | |
| echo "Integration tests failed on one or more OS/arch combinations" | |
| exit 1 | |
| fi | |
| smoke-test: | |
| needs: smoke-test-arch | |
| if: always() | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check smoke-test results | |
| run: | | |
| if [ "${{ needs.smoke-test-arch.result }}" != "success" ]; then | |
| echo "Smoke tests failed on one or more architectures" | |
| exit 1 | |
| fi | |
| build: | |
| needs: build-arch | |
| if: always() | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check build results | |
| run: | | |
| if [ "${{ needs.build-arch.result }}" != "success" ]; then | |
| echo "Build failed on one or more architectures" | |
| exit 1 | |
| fi |