-
Notifications
You must be signed in to change notification settings - Fork 2
86 lines (75 loc) · 3.08 KB
/
Copy pathci-profile.yml
File metadata and controls
86 lines (75 loc) · 3.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
name: CI profile
on:
schedule:
- cron: "17 3 * * 1"
workflow_dispatch:
concurrency:
group: ci-profile-${{ github.ref }}
cancel-in-progress: true
jobs:
server-integration:
name: "Server integration profile"
runs-on: ubuntu-latest
timeout-minutes: 30
permissions:
contents: read
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- uses: ./.github/actions/setup-node-pnpm
with:
install: "none"
- uses: ./.github/actions/setup-caches
with:
cache-type: application-server-reactor
os: ${{ runner.os }}
- name: Restore performance history
if: github.ref_name == github.event.repository.default_branch
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: ci-profile-history
key: ci-profile-history-${{ github.run_id }}
restore-keys: ci-profile-history-
- name: Run integration suite with JFR
run: |
mkdir -p ci-metrics
/usr/bin/time -v -o ci-metrics/server-integration-resource.txt \
pnpm run test:server:integration \
-DargLine=-XX:StartFlightRecording=filename=target/integration-profile.jfr,settings=profile,dumponexit=true \
-Dlogging.level.org.springframework.test.context.cache=DEBUG \
2>&1 | tee ci-metrics/server-integration.log
- name: Summarize integration results
if: always()
continue-on-error: true
run: >-
pnpm run summarize:test-results "Server Integration Profile"
server/application/target/surefire-reports ci-metrics/server-integration-profile.json
ci-metrics/server-integration.log ci-metrics/server-integration-resource.txt
- name: Enforce performance budgets
if: success() && github.ref_name == github.event.repository.default_branch
run: |
node scripts/check-ci-performance.ts ci-metrics/server-integration-profile.json ci-profile-history
mkdir -p ci-profile-history
cp ci-metrics/server-integration-profile.json "ci-profile-history/${{ github.run_id }}.json"
- name: Extract database cleanup timings
if: always()
continue-on-error: true
run: >-
jfr print --events hephaestus.test.DatabaseCleanup
server/application/target/integration-profile.jfr
> ci-metrics/database-cleanup.jfr.txt
- name: Upload profile
if: always()
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: server-integration-profile-${{ github.run_id }}
path: |
server/application/target/integration-profile.jfr
server/application/target/surefire-reports
ci-metrics/server-integration-profile.json
ci-metrics/server-integration.log
ci-metrics/server-integration-resource.txt
ci-metrics/database-cleanup.jfr.txt
if-no-files-found: warn
retention-days: 14