perf(flutter): Move Android JNI work to core worker to avoid work on main isolate #358
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
| name: Size Analysis | |
| on: | |
| push: | |
| branches: | |
| - main | |
| paths: | |
| - 'packages/**' | |
| - 'metrics/flutter.properties' | |
| - '.github/workflows/size-analysis.yml' | |
| - '.github/actions/size-analysis-setup/**' | |
| pull_request: | |
| paths: | |
| - 'packages/**' | |
| - 'metrics/flutter.properties' | |
| - '.github/workflows/size-analysis.yml' | |
| - '.github/actions/size-analysis-setup/**' | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | |
| cancel-in-progress: true | |
| env: | |
| SENTRY_ORG: sentry-sdks | |
| SENTRY_PROJECT: sentry-flutter | |
| SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }} | |
| jobs: | |
| android: | |
| name: Android | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 30 | |
| defaults: | |
| run: | |
| working-directory: packages/flutter/example | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 | |
| with: | |
| fetch-depth: 0 | |
| - uses: actions/setup-java@be666c2fcd27ec809703dec50e508c2fdc7f6654 # v5 | |
| with: | |
| distribution: 'adopt' | |
| java-version: '17' | |
| - uses: ./.github/actions/size-analysis-setup | |
| - name: Build Android Appbundle | |
| run: | | |
| flutter build appbundle \ | |
| --release \ | |
| --obfuscate \ | |
| --split-debug-info=build/symbols \ | |
| --build-name "$SIZE_VERSION" \ | |
| --build-number "$SIZE_BUILD" | |
| - name: Upload Android Bundle to Sentry Size Analysis | |
| if: env.SENTRY_AUTH_TOKEN != '' | |
| run: | | |
| sentry-cli build upload \ | |
| "build/app/outputs/bundle/release/app-release.aab" \ | |
| --org "${{ env.SENTRY_ORG }}" \ | |
| --project "${{ env.SENTRY_PROJECT }}" \ | |
| --build-configuration "Release" | |
| ios: | |
| name: iOS | |
| runs-on: macos-latest | |
| timeout-minutes: 45 | |
| defaults: | |
| run: | |
| working-directory: packages/flutter/example | |
| steps: | |
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6 | |
| with: | |
| fetch-depth: 0 | |
| - uses: ./.github/actions/size-analysis-setup | |
| - name: Build Flutter iOS | |
| run: | | |
| flutter build ipa \ | |
| --release \ | |
| --no-codesign \ | |
| --obfuscate \ | |
| --split-debug-info=build/symbols \ | |
| --build-name "$SIZE_VERSION" \ | |
| --build-number "$SIZE_BUILD" | |
| - name: Upload iOS XCArchive to Sentry Size Analysis | |
| if: env.SENTRY_AUTH_TOKEN != '' | |
| run: | | |
| sentry-cli build upload \ | |
| "build/ios/archive/Runner.xcarchive" \ | |
| --org "${{ env.SENTRY_ORG }}" \ | |
| --project "${{ env.SENTRY_PROJECT }}" \ | |
| --build-configuration "Release" |