-
Notifications
You must be signed in to change notification settings - Fork 7
418 lines (377 loc) · 13.5 KB
/
run-alter-stress.yml
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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
name: Run CI/CD alter stress tests
run-name: ${{ inputs.custom_run_name || format('{0} | Stress {1} | Provider {2} | Arch {3}', inputs.version, inputs.scenario, inputs.storage_provider, inputs.architecture) }}
on:
workflow_dispatch:
inputs:
package:
description: "Package either 'docker://' or 'https://'. Example: 'https://s3.amazonaws.com/clickhouse-builds/23.3/.../package_release/clickhouse-common-static_23.3.1.64_amd64.deb', or 'docker://altinity/clickhouse-server:23.8.8'"
required: true
type: string
default: docker://altinity/clickhouse-server:23.8.8.21.altinitystable
version:
description: "Expected version. Example: 23.3.1.64"
required: true
type: string
scenario:
description: "Stress scenario to run (default: safe)"
type: choice
options:
- safe
- parts
- columns and indexes unsafe
- add remove replicas
- restarts
- full disk
- network faults
- one by one
- pairs/columns and part manipulation
- pairs/columns and ttl
- pairs/columns and projections
- pairs/columns and indexes
- pairs/columns and restarts
- pairs/columns and add remove replicas
- pairs/part manipulation and ttl
- pairs/part manipulation and projections
- pairs/part manipulation and indexes
- pairs/part manipulation and restarts
- pairs/part manipulation and network restarts
- pairs/ttl and projections
- pairs/ttl and indexes
- pairs/ttl and restarts
- pairs/ttl and network restarts
- pairs/ttl and add remove replicas
- pairs/projections and indexes
- pairs/projections and restarts
- pairs/projections and network restarts
- pairs/projections and add remove replicas
- pairs/indexes and restarts
- pairs/indexes and network restarts
- pairs/indexes and add remove replicas
- pairs/restarts and network restarts
- pairs/restarts and add remove replicas
- pairs/network restarts and add remove replicas
storage_provider:
description: "Storage Provider to use (default: minio)"
type: choice
options:
- minio
- local
- aws_s3
- gcs
- all
architecture:
description: "Runner architecture to use (default: x86)"
type: choice
options:
- x86
- ARM
- all
artifacts:
description: "Artifact S3 bucket"
type: choice
options:
- public
- internal
output_format:
description: "Testflows output style."
type: choice
options:
- new-fails
- classic
- nice
- fails
- slick
- brisk
- quiet
- short
- manual
- dots
- progress
- raw
ref:
description: "Commit SHA to checkout. Default: current (empty string)."
type: string
default: ""
extra_args:
description: "Extra test program arguments. Default: none (empty string)."
type: string
default: ""
custom_run_name:
description: 'Custom run name (optional)'
required: false
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_REPORT_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_REPORT_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: ${{ secrets.AWS_REPORT_REGION }}
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
PYTHONIOENCODING: utf-8
clickhouse_binary_path: ${{ inputs.package }}
version: ${{ inputs.version }}
artifacts: ${{ inputs.artifacts }}
args: --test-to-end
--no-colors
--local
--collect-service-logs
--output ${{ inputs.output_format }}
--parallel ${{ vars.PARALLEL }}
--attr project="${GITHUB_REPOSITORY}" project.id="${GITHUB_REPOSITORY_ID}" user.name="${GITHUB_ACTOR}" version="${{ inputs.version }}" package="${{ inputs.package }}" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="${GITHUB_SHA}" job.id="${GITHUB_RUN_ID}" job.url="${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID}" arch="$(uname -i)"
--log raw.log ${{ inputs.extra_args }}
--stress
--only ":/combinations/:/${{ inputs.scenario }}*"
artifact_paths: |
./report.html
./*.log.txt
./*.log
./*.html
./*/_instances/*.log
./*/_instances/*/logs/*.log
./*/*/_instances/*/logs/*.log
./*/*/_instances/*.log
jobs:
alter_stress_aws_x86:
runs-on: [self-hosted, type-cpx51, image-x86-app-docker-ce]
timeout-minutes: 10000
env:
SUITE: alter/stress
STORAGE: /aws_x86
if: ${{ contains('all aws_s3', inputs.storage_provider) && contains('all x86', inputs.architecture) }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Setup
run: .github/setup.sh
- name: Run ${{ env.SUITE }} suite
run: python3
-u ${{ env.SUITE }}/regression.py
--storage aws_s3
--aws-s3-bucket ${{ secrets.AWS_BUCKET }}
--aws-s3-region ${{ secrets.AWS_REGION }}
--aws-s3-key-id ${{ secrets.AWS_KEY_ID }}
--aws-s3-access-key ${{ secrets.AWS_ACCESS_KEY }}
--clickhouse-binary-path ${{ env.clickhouse_binary_path }}
--clickhouse-version ${{ env.version }}
${{ env.args }}
- name: Create and upload logs
if: always()
run: .github/create_and_upload_logs.sh ${{ vars.UPLOAD_LOGS }}
- uses: actions/upload-artifact@v3
if: always()
with:
name: alter-stress-aws-x86-artifacts
path: ${{ env.artifact_paths}}
alter_stress_gcs_x86:
runs-on: [self-hosted, type-cpx51, image-x86-app-docker-ce]
timeout-minutes: 10000
env:
SUITE: alter/stress
STORAGE: /gcs_x86
if: ${{ contains('all gcs', inputs.storage_provider) && contains('all x86', inputs.architecture) }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Setup
run: .github/setup.sh
- name: Run ${{ env.SUITE }} suite
run: python3
-u ${{ env.SUITE }}/regression.py
--storage gcs
--gcs-uri ${{ secrets.GCS_URI }}
--gcs-key-id ${{ secrets.GCS_KEY_ID }}
--gcs-key-secret ${{ secrets.GCS_KEY_SECRET }}
--clickhouse-binary-path ${{ env.clickhouse_binary_path }}
--clickhouse-version ${{ env.version }}
${{ env.args }}
- name: Create and upload logs
if: always()
run: .github/create_and_upload_logs.sh ${{ vars.UPLOAD_LOGS }}
- uses: actions/upload-artifact@v3
if: always()
with:
name: alter-stress-gcs-x86-artifacts
path: ${{ env.artifact_paths}}
alter_stress_minio_x86:
runs-on: [self-hosted, type-cpx51, image-x86-app-docker-ce]
timeout-minutes: 10000
env:
SUITE: alter/stress
STORAGE: /minio_x86
if: ${{ contains('all minio', inputs.storage_provider) && contains('all x86', inputs.architecture) }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Setup
run: .github/setup.sh
- name: Run ${{ env.SUITE }} suite
run: python3
-u ${{ env.SUITE }}/regression.py
--storage minio
--clickhouse-binary-path ${{ env.clickhouse_binary_path }}
--clickhouse-version ${{ env.version }}
${{ env.args }}
- name: Create and upload logs
if: always()
run: .github/create_and_upload_logs.sh ${{ vars.UPLOAD_LOGS }}
- uses: actions/upload-artifact@v3
if: always()
with:
name: alter-stress-minio-x86-artifacts
path: ${{ env.artifact_paths}}
alter_stress_local_x86:
runs-on: [self-hosted, type-cpx51, image-x86-app-docker-ce]
timeout-minutes: 10000
env:
SUITE: alter/stress
STORAGE: /local_x86
if: ${{ contains('all local', inputs.storage_provider) && contains('all x86', inputs.architecture) }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Setup
run: .github/setup.sh
- name: Run ${{ env.SUITE }} suite
run: python3
-u ${{ env.SUITE }}/regression.py
--storage local
--clickhouse-binary-path ${{ env.clickhouse_binary_path }}
--clickhouse-version ${{ env.version }}
${{ env.args }}
- name: Create and upload logs
if: always()
run: .github/create_and_upload_logs.sh ${{ vars.UPLOAD_LOGS }}
- uses: actions/upload-artifact@v3
if: always()
with:
name: alter-stress-local-x86-artifacts
path: ${{ env.artifact_paths}}
alter_stress_aws_arm:
runs-on: [self-hosted, type-cax41, image-arm-app-docker-ce]
timeout-minutes: 10000
env:
SUITE: alter/stress
STORAGE: /aws_arm
if: ${{ contains('all aws_s3', inputs.storage_provider) && contains('all ARM', inputs.architecture) }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Setup
run: .github/setup.sh
- name: Run ${{ env.SUITE }} suite
run: python3
-u ${{ env.SUITE }}/regression.py
--storage aws_s3
--aws-s3-bucket ${{ secrets.AWS_BUCKET }}
--aws-s3-region ${{ secrets.AWS_REGION }}
--aws-s3-key-id ${{ secrets.AWS_KEY_ID }}
--aws-s3-access-key ${{ secrets.AWS_ACCESS_KEY }}
--clickhouse-binary-path ${{ env.clickhouse_binary_path }}
--clickhouse-version ${{ env.version }}
${{ env.args }}
- name: Create and upload logs
if: always()
run: .github/create_and_upload_logs.sh ${{ vars.UPLOAD_LOGS }}
- uses: actions/upload-artifact@v3
if: always()
with:
name: alter-stress-aws-arm-artifacts
path: ${{ env.artifact_paths}}
alter_stress_gcs_arm:
runs-on: [self-hosted, type-cax41, image-arm-app-docker-ce]
timeout-minutes: 10000
env:
SUITE: alter/stress
STORAGE: /gcs_arm
if: ${{ contains('all gcs', inputs.storage_provider) && contains('all ARM', inputs.architecture) }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Setup
run: .github/setup.sh
- name: Run ${{ env.SUITE }} suite
run: python3
-u ${{ env.SUITE }}/regression.py
--storage gcs
--gcs-uri ${{ secrets.GCS_URI }}
--gcs-key-id ${{ secrets.GCS_KEY_ID }}
--gcs-key-secret ${{ secrets.GCS_KEY_SECRET }}
--clickhouse-binary-path ${{ env.clickhouse_binary_path }}
--clickhouse-version ${{ env.version }}
${{ env.args }}
- name: Create and upload logs
if: always()
run: .github/create_and_upload_logs.sh ${{ vars.UPLOAD_LOGS }}
- uses: actions/upload-artifact@v3
if: always()
with:
name: alter-stress-gcs-arm-artifacts
path: ${{ env.artifact_paths}}
alter_stress_minio_arm:
runs-on: [self-hosted, type-cax41, image-arm-app-docker-ce]
timeout-minutes: 10000
env:
SUITE: alter/stress
STORAGE: /minio_arm
if: ${{ contains('all minio', inputs.storage_provider) && contains('all ARM', inputs.architecture) }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Setup
run: .github/setup.sh
- name: Run ${{ env.SUITE }} suite
run: python3
-u ${{ env.SUITE }}/regression.py
--storage minio
--clickhouse-binary-path ${{ env.clickhouse_binary_path }}
--clickhouse-version ${{ env.version }}
${{ env.args }}
- name: Create and upload logs
if: always()
run: .github/create_and_upload_logs.sh ${{ vars.UPLOAD_LOGS }}
- uses: actions/upload-artifact@v3
if: always()
with:
name: alter-stress-minio-arm-artifacts
path: ${{ env.artifact_paths}}
alter_stress_local_arm:
runs-on: [self-hosted, type-cax41, image-arm-app-docker-ce]
timeout-minutes: 10000
env:
SUITE: alter/stress
STORAGE: /local_arm
if: ${{ contains('all local', inputs.storage_provider) && contains('all ARM', inputs.architecture) }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ inputs.ref }}
- name: Setup
run: .github/setup.sh
- name: Run ${{ env.SUITE }} suite
run: python3
-u ${{ env.SUITE }}/regression.py
--storage local
--clickhouse-binary-path ${{ env.clickhouse_binary_path }}
--clickhouse-version ${{ env.version }}
${{ env.args }}
- name: Create and upload logs
if: always()
run: .github/create_and_upload_logs.sh ${{ vars.UPLOAD_LOGS }}
- uses: actions/upload-artifact@v3
if: always()
with:
name: alter-stress-local-arm-artifacts
path: ${{ env.artifact_paths}}