feat: make BLQ stale threshold and static friction runtime-configurab… #18059
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
| on: | |
| pull_request: | |
| push: | |
| branches: | |
| - master | |
| - release/** | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | |
| cancel-in-progress: true | |
| jobs: | |
| build-multiplatform: | |
| strategy: | |
| matrix: | |
| include: | |
| - os: ubuntu-24.04 | |
| platform: amd64 | |
| - os: ubuntu-24.04-arm | |
| platform: arm64 | |
| runs-on: ${{ matrix.os }} | |
| name: build-${{ matrix.platform }} | |
| permissions: | |
| contents: read | |
| packages: write | |
| if: github.repository_owner == 'getsentry' | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - uses: getsentry/action-build-and-push-images@8fc75e483c09a68721f2c8951292ee17f8821766 | |
| with: | |
| image_name: 'snuba' | |
| platforms: linux/${{ matrix.platform }} | |
| dockerfile_path: 'Dockerfile' | |
| tag_suffix: -${{ matrix.platform }} | |
| ghcr: true | |
| tag_nightly: false | |
| tag_latest: false | |
| build-production: | |
| runs-on: ubuntu-24.04 | |
| name: Build and push production image | |
| permissions: | |
| contents: read | |
| id-token: write | |
| if: ${{ github.ref_name == 'master' }} | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - uses: getsentry/action-build-and-push-images@8fc75e483c09a68721f2c8951292ee17f8821766 | |
| with: | |
| image_name: 'snuba' | |
| platforms: linux/amd64 | |
| dockerfile_path: './Dockerfile' | |
| ghcr: false | |
| tag_nightly: false | |
| tag_latest: false | |
| google_ar: true | |
| google_ar_image_name: us-docker.pkg.dev/sentryio/snuba-mr/image | |
| google_workload_identity_provider: projects/868781662168/locations/global/workloadIdentityPools/prod-github/providers/github-oidc-pool | |
| google_service_account: gha-gcr-push@sac-prod-sa.iam.gserviceaccount.com | |
| # Distroless image — for testing before switching production | |
| build-distroless-multiplatform: | |
| strategy: | |
| matrix: | |
| include: | |
| - os: ubuntu-24.04 | |
| platform: amd64 | |
| - os: ubuntu-24.04-arm | |
| platform: arm64 | |
| runs-on: ${{ matrix.os }} | |
| name: build-distroless-${{ matrix.platform }} | |
| permissions: | |
| contents: read | |
| packages: write | |
| if: github.repository_owner == 'getsentry' | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - uses: getsentry/action-build-and-push-images@8fc75e483c09a68721f2c8951292ee17f8821766 | |
| with: | |
| image_name: 'snuba' | |
| platforms: linux/${{ matrix.platform }} | |
| dockerfile_path: 'Dockerfile' | |
| build_target: 'application-distroless' | |
| tag_suffix: -distroless-${{ matrix.platform }} | |
| ghcr: true | |
| tag_nightly: false | |
| tag_latest: false | |
| # Debug distroless image — with busybox for troubleshooting | |
| build-debug-multiplatform: | |
| strategy: | |
| matrix: | |
| include: | |
| - os: ubuntu-24.04 | |
| platform: amd64 | |
| - os: ubuntu-24.04-arm | |
| platform: arm64 | |
| runs-on: ${{ matrix.os }} | |
| name: build-debug-${{ matrix.platform }} | |
| permissions: | |
| contents: read | |
| packages: write | |
| if: github.repository_owner == 'getsentry' | |
| steps: | |
| - uses: actions/checkout@v6.0.2 | |
| - uses: getsentry/action-build-and-push-images@8fc75e483c09a68721f2c8951292ee17f8821766 | |
| with: | |
| image_name: 'snuba' | |
| platforms: linux/${{ matrix.platform }} | |
| dockerfile_path: 'Dockerfile' | |
| build_target: 'application-distroless-debug' | |
| tag_suffix: -debug-${{ matrix.platform }} | |
| ghcr: true | |
| tag_nightly: false | |
| tag_latest: false | |
| assemble: | |
| needs: [build-multiplatform] | |
| if: ${{ (github.ref_name == 'master' || startsWith(github.ref_name, 'release/')) && github.event_name != 'pull_request' }} | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| packages: write | |
| steps: | |
| - name: Docker Login | |
| run: docker login --username '${{ github.actor }}' --password-stdin ghcr.io <<< "$GHCR_TOKEN" | |
| env: | |
| GHCR_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Create multiplatform manifests | |
| run: | | |
| docker buildx imagetools create \ | |
| --tag ghcr.io/getsentry/snuba:${{ github.sha }} \ | |
| --tag ghcr.io/getsentry/snuba:nightly \ | |
| ghcr.io/getsentry/snuba:${{ github.sha }}-amd64 \ | |
| ghcr.io/getsentry/snuba:${{ github.sha }}-arm64 | |
| assemble-distroless: | |
| needs: [build-distroless-multiplatform] | |
| if: ${{ (github.ref_name == 'master' || startsWith(github.ref_name, 'release/')) && github.event_name != 'pull_request' }} | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| packages: write | |
| steps: | |
| - name: Docker Login | |
| run: docker login --username '${{ github.actor }}' --password-stdin ghcr.io <<< "$GHCR_TOKEN" | |
| env: | |
| GHCR_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Create distroless multiplatform manifests | |
| run: | | |
| docker buildx imagetools create \ | |
| --tag ghcr.io/getsentry/snuba:${{ github.sha }}-distroless \ | |
| --tag ghcr.io/getsentry/snuba:nightly-distroless \ | |
| ghcr.io/getsentry/snuba:${{ github.sha }}-distroless-amd64 \ | |
| ghcr.io/getsentry/snuba:${{ github.sha }}-distroless-arm64 | |
| assemble-debug: | |
| needs: [build-debug-multiplatform] | |
| if: ${{ (github.ref_name == 'master' || startsWith(github.ref_name, 'release/')) && github.event_name != 'pull_request' }} | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| packages: write | |
| steps: | |
| - name: Docker Login | |
| run: docker login --username '${{ github.actor }}' --password-stdin ghcr.io <<< "$GHCR_TOKEN" | |
| env: | |
| GHCR_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Create debug multiplatform manifests | |
| run: | | |
| docker buildx imagetools create \ | |
| --tag ghcr.io/getsentry/snuba:${{ github.sha }}-debug \ | |
| --tag ghcr.io/getsentry/snuba:nightly-debug \ | |
| ghcr.io/getsentry/snuba:${{ github.sha }}-debug-amd64 \ | |
| ghcr.io/getsentry/snuba:${{ github.sha }}-debug-arm64 | |
| self-hosted-end-to-end: | |
| needs: [build-multiplatform, assemble] | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 30 | |
| steps: | |
| - name: Run Sentry self-hosted e2e CI | |
| uses: getsentry/self-hosted@master | |
| with: | |
| project_name: snuba | |
| image_url: ghcr.io/getsentry/snuba:${{ github.sha }} | |
| CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} |