Skip to content

Commit 19bdb13

Browse files
authored
build: upgrade artifacts actions to v4 (#13143)
Upgrade action to artifacts v4 (previous version did some convenient merging for us)
1 parent 7e1a641 commit 19bdb13

File tree

2 files changed

+42
-15
lines changed

2 files changed

+42
-15
lines changed

.github/workflows/build.yml

Lines changed: 41 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -409,10 +409,11 @@ jobs:
409409
DEPENDENCY_CACHE_KEY: ${{ needs.job_build.outputs.dependency_cache_key }}
410410

411411
- name: Extract Profiling Node Prebuilt Binaries
412-
uses: actions/download-artifact@v3
412+
uses: actions/download-artifact@v4
413413
with:
414-
name: profiling-node-binaries-${{ github.sha }}
414+
pattern: profiling-node-binaries-${{ github.sha }}-*
415415
path: ${{ github.workspace }}/packages/profiling-node/lib/
416+
merge-multiple: true
416417

417418
- name: Pack tarballs
418419
run: yarn build:tarball
@@ -902,16 +903,15 @@ jobs:
902903
run: yarn lerna run build:lib --scope @sentry/profiling-node
903904

904905
- name: Extract Profiling Node Prebuilt Binaries
905-
# @TODO: v4 breaks convenient merging of same name artifacts
906-
# https://github.com/actions/upload-artifact/issues/478
907906
if: |
908907
(needs.job_get_metadata.outputs.changed_profiling_node_bindings == 'true') ||
909908
(needs.job_get_metadata.outputs.is_release == 'true') ||
910909
(github.event_name != 'pull_request')
911-
uses: actions/download-artifact@v3
910+
uses: actions/download-artifact@v4
912911
with:
913-
name: profiling-node-binaries-${{ github.sha }}
912+
pattern: profiling-node-binaries-${{ github.sha }}-*
914913
path: ${{ github.workspace }}/packages/profiling-node/lib/
914+
merge-multiple: true
915915

916916
- name: Build Profiling tarball
917917
run: yarn build:tarball
@@ -1231,11 +1231,11 @@ jobs:
12311231
- name: Build Profiling Node
12321232
run: yarn lerna run build:lib --scope @sentry/profiling-node
12331233
- name: Extract Profiling Node Prebuilt Binaries
1234-
uses: actions/download-artifact@v3
1234+
uses: actions/download-artifact@v4
12351235
with:
1236-
name: profiling-node-binaries-${{ github.sha }}
1236+
pattern: profiling-node-binaries-${{ github.sha }}-*
12371237
path: ${{ github.workspace }}/packages/profiling-node/lib/
1238-
1238+
merge-multiple: true
12391239
- name: Restore tarball cache
12401240
uses: actions/cache/restore@v4
12411241
with:
@@ -1359,104 +1359,132 @@ jobs:
13591359
# x64 glibc
13601360
- os: ubuntu-20.04
13611361
node: 16
1362+
binary: linux-x64-glibc-93
13621363
- os: ubuntu-20.04
13631364
node: 18
1365+
binary: linux-x64-glibc-108
13641366
- os: ubuntu-20.04
13651367
node: 20
1368+
binary: linux-x64-glibc-115
13661369
- os: ubuntu-20.04
13671370
node: 22
1371+
binary: linux-x64-glibc-127
13681372

13691373
# x64 musl
13701374
- os: ubuntu-20.04
13711375
container: node:16-alpine3.16
1376+
binary: linux-x64-musl-93
13721377
node: 16
13731378
- os: ubuntu-20.04
13741379
container: node:18-alpine3.17
13751380
node: 18
1381+
binary: linux-x64-musl-108
13761382
- os: ubuntu-20.04
13771383
container: node:20-alpine3.17
13781384
node: 20
1385+
binary: linux-x64-musl-115
13791386
- os: ubuntu-20.04
13801387
container: node:22-alpine3.18
13811388
node: 22
1389+
binary: linux-x64-musl-127
13821390

13831391
# arm64 glibc
13841392
- os: ubuntu-20.04
13851393
arch: arm64
13861394
node: 16
1395+
binary: linux-arm64-glibc-93
13871396
- os: ubuntu-20.04
13881397
arch: arm64
13891398
node: 18
1399+
binary: linux-arm64-glibc-108
13901400
- os: ubuntu-20.04
13911401
arch: arm64
13921402
node: 20
1403+
binary: linux-arm64-glibc-115
13931404
- os: ubuntu-20.04
13941405
arch: arm64
13951406
node: 22
1407+
binary: linux-arm64-glibc-127
13961408

13971409
# arm64 musl
13981410
- os: ubuntu-20.04
13991411
container: node:16-alpine3.16
14001412
arch: arm64
14011413
node: 16
1414+
binary: linux-arm64-musl-93
14021415
- os: ubuntu-20.04
14031416
arch: arm64
14041417
container: node:18-alpine3.17
14051418
node: 18
1419+
binary: linux-arm64-musl-108
14061420
- os: ubuntu-20.04
14071421
arch: arm64
14081422
container: node:20-alpine3.17
14091423
node: 20
1424+
binary: linux-arm64-musl-115
14101425
- os: ubuntu-20.04
14111426
arch: arm64
14121427
container: node:22-alpine3.18
14131428
node: 22
1429+
binary: linux-arm64-musl-127
14141430

14151431
# macos x64
14161432
- os: macos-13
14171433
node: 16
14181434
arch: x64
1435+
binary: darwin-x64-93
14191436
- os: macos-13
14201437
node: 18
14211438
arch: x64
1439+
binary: darwin-x64-108
14221440
- os: macos-13
14231441
node: 20
14241442
arch: x64
1443+
binary: darwin-x64-115
14251444
- os: macos-13
14261445
node: 22
14271446
arch: x64
1447+
binary: darwin-x64-127
14281448

14291449
# macos arm64
14301450
- os: macos-13
14311451
arch: arm64
14321452
node: 16
14331453
target_platform: darwin
1454+
binary: darwin-arm64-93
14341455
- os: macos-13
14351456
arch: arm64
14361457
node: 18
14371458
target_platform: darwin
1459+
binary: darwin-arm64-108
14381460
- os: macos-13
14391461
arch: arm64
14401462
node: 20
14411463
target_platform: darwin
1464+
binary: darwin-arm64-115
14421465
- os: macos-13
14431466
arch: arm64
14441467
node: 22
14451468
target_platform: darwin
1469+
binary: darwin-arm64-127
14461470

14471471
# windows x64
14481472
- os: windows-2022
14491473
node: 16
14501474
arch: x64
1475+
binary: win32-x64-93
14511476
- os: windows-2022
14521477
node: 18
14531478
arch: x64
1479+
binary: win32-x64-108
14541480
- os: windows-2022
14551481
node: 20
14561482
arch: x64
1483+
binary: win32-x64-115
14571484
- os: windows-2022
14581485
node: 22
14591486
arch: x64
1487+
binary: win32-x64-127
14601488

14611489
steps:
14621490
- name: Setup (alpine)
@@ -1588,10 +1616,8 @@ jobs:
15881616
yarn lerna run test --scope @sentry/profiling-node
15891617
15901618
- name: Archive Binary
1591-
# @TODO: v4 breaks convenient merging of same name artifacts
1592-
# https://github.com/actions/upload-artifact/issues/478
1593-
uses: actions/upload-artifact@v3
1619+
uses: actions/upload-artifact@v4
15941620
with:
1595-
name: profiling-node-binaries-${{ github.sha }}
1596-
path: |
1597-
${{ github.workspace }}/packages/profiling-node/lib/*.node
1621+
name: profiling-node-binaries-${{ github.sha }}-${{ matrix.binary }}
1622+
path: ${{ github.workspace }}/packages/profiling-node/lib/sentry_cpu_profiler-${{matrix.binary}}.node
1623+
if-no-files-found: error

packages/profiling-node/bindings/cpu_profiler.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ enum ProfileFormat {
2828
kFormatThread = 0,
2929
kFormatChunk = 1,
3030
};
31+
3132
// Allow users to override the default logging mode via env variable. This is
3233
// useful because sometimes the flow of the profiled program can be to execute
3334
// many sequential transaction - in that case, it may be preferable to set eager

0 commit comments

Comments
 (0)