-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Test Synapse against Complement with workers. #12810
Changes from 4 commits
be69bd2
322d22f
a974ccb
a2ae63e
9b3cdeb
7f9870e
d539339
50a9264
06b1221
5f1efa4
b998416
58819e1
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -310,6 +310,26 @@ jobs: | |||||
needs: linting-done | ||||||
runs-on: ubuntu-latest | ||||||
|
||||||
strategy: | ||||||
fail-fast: false | ||||||
matrix: | ||||||
include: | ||||||
# GHA requires all matrix configurations to have at least one value. We don't want to set one here though. | ||||||
- _: monolith | ||||||
|
||||||
# Test with workers | ||||||
- workers: workers | ||||||
regex: 'A-Ea-e' | ||||||
|
||||||
- workers: workers | ||||||
regex: 'F-Lf-l' | ||||||
|
||||||
- workers: workers | ||||||
regex: 'M-Qm-q' | ||||||
|
||||||
- workers: workers | ||||||
regex: 'R-Zr-z' | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I have reservations over this is a useful thing to do. We are constrained as an organisation as to the number of GHA jobs we can run concurrently (to 60, according to https://docs.github.com/en/actions/learn-github-actions/usage-limits-billing-and-administration#usage-limits). Splitting the tests up this way does nothing to reduce the total amount of GHA worker time used by our tests, but does increase the chances of us monopolising the workers. An alternative might be to exclude worker-mode-complement from the le sigh. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Right, fair enough, I didn't realise we had this limit (well, I assumed there must be a limit, but I didn't know how much it was or how concerned we were about it). Perhaps it may make sense, for now, to:
Whilst testing, I've been cheating a bit and making Complement start before the lints are done; this gives it a few minutes headstart and then it's not the slowest thing on the list. If we're interested that much in shaving some time off, it could be worth considering, though I'd rather get some real time shavings if possible. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
yeah, let's try what you suggest for now There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Turns out you can't use a There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Are you sure about this? We have examples of doing so, e.g. synapse/.github/workflows/latest_deps.yml Line 58 in 57fac2a
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Oh, perhaps you mean the job-level if rather than the step-level if There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Yeah, see https://github.com/matrix-org/synapse/actions/runs/2414412187/workflow#L310 I don't think that example is using it at the same level with the same meaning (we want to skip a job, not a step) |
||||||
|
||||||
steps: | ||||||
# The path is set via a file given by $GITHUB_PATH. We need both Go 1.17 and GOPATH on the path to run Complement. | ||||||
# See https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#adding-a-system-path | ||||||
|
@@ -356,7 +376,7 @@ jobs: | |||||
|
||||||
- run: | | ||||||
set -o pipefail | ||||||
COMPLEMENT_DIR=`pwd`/complement synapse/scripts-dev/complement.sh -json 2>&1 | gotestfmt | ||||||
WORKERS=${{ matrix.workers && 1 }} COMPLEMENT_DIR=`pwd`/complement synapse/scripts-dev/complement.sh -json ${{ matrix.regex && format('-run Test[{0}]', matrix.regex) || '' }} 2>&1 | gotestfmt | ||||||
shell: bash | ||||||
name: Run Complement Tests | ||||||
|
||||||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Test Synapse against Complement with workers. |
Uh oh!
There was an error while loading. Please reload this page.