action: tav - #3127
Conversation
Requires to filter by changes
* upstream/main: (44 commits) action: abort builds when new commit (elastic#3196) docs: note that 3.40.0 was bad release (elastic#3194) chore(deps-dev): bump @babel/cli from 7.20.7 to 7.21.0 (elastic#3170) chore(deps-dev): bump @babel/core from 7.20.2 to 7.21.0 (elastic#3169) ci: drop max-parallel for GH actions (elastic#3191) test: correct sense of test message (elastic#3186) 3.43.0 (elastic#3184) test, ci: some small changes (elastic#3183) ci: limit parallel GH Action test runs to try to avoid 429 errors on checkout (elastic#3180) fix: transaction name for Next.js API routes in next@13.2 was broken (elastic#3178) mongodb@5 support (elastic#3177) chore(deps-dev): bump body-parser from 1.20.1 to 1.20.2 (elastic#3171) chore(deps-dev): bump restify from 11.0.0 to 11.1.0 (elastic#3172) docs: minor fix in README for Azure Functions example (elastic#3175) feat: Make Agent.flush() return a Promise if no callback is passed as param (elastic#3167) chore(deps-dev): bump @types/node from 18.11.9 to 18.14.0 (elastic#3165) chore(deps-dev): bump @hapi/hapi from 21.2.1 to 21.3.0 (elastic#3166) chore(deps-dev): bump undici from 5.19.1 to 5.20.0 (elastic#3164) chore(deps-dev): bump fastify from 4.12.0 to 4.13.0 (elastic#3154) Use composite action for updatecli workflow (elastic#3162) ...
trentm
left a comment
There was a problem hiding this comment.
How can one trigger a TAV run on a PR?
- a full TAV run
- just for a particular module
- just for a particular node version
| - "12" | ||
| - "10" | ||
| - "8" | ||
| framework: |
There was a problem hiding this comment.
nit: Maybe call this "module" instead of "framework". This is minor, however.
I probably misunderstood what we discussed online the other day, somehow I thought the smart jenkins stuff was never used hence I kept it simple to run only on the main branch or manually when needed. If the above is needed, then let's discuss about each individual scenario:
A few other questions:
Thanks |
Co-authored-by: Trent Mick <trentm@gmail.com>
@v1v I think we only need the ability to manually start a TAV test run. I don't think we need any smart automatic triggering. I also don't have any requirements for how we do that -- any of the following would be fine: a GitHub comment, clicking some GitHub checks UI, running some Should we be able to see some "TAV / ..." GitHub checks on this PR? |
trentm
left a comment
There was a problem hiding this comment.
Approving, though I'm still not sure what the suggested way to manually trigger a TAV run is.
I'm afraid new GH actions coming from forked repositories are not executed. Let me create a branch in the upstream and cherry-pick the changes so you can see how it looks like. See #3221 |
Oh, right. Thanks for doing that. This looks very good. Some TAV comparisons between GH Actions and Jenkins:
|
|
@v1v Do you know if there will be a way to manually run just a part of the TAV tests on a PR? For example, say I have a PR that is working on the "fastify" module. Can I run the TAV tests for module=fastify for either all node versions, or just a subset of the node versions? This doesn't work: because the This isn't a requirement for this PR. We could look into this separately. |
|
I notice this from https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstrategymatrix
Currently we have 35 modules * 7 node versions = 245 jobs. So we are very close to the maximum currently. :) |
I'd like to work on this in a follow up, so we can use one of the above proposals (#3127 (comment))
We managed to use buckets in the apm-agent-python: It's not ideal, otherwise if possible we could create combinations of two modules per runner, though I don't know whether that could cause any other issues (tearing down the environment might be required)
You can use the existing opentelemetry data :) https://ela.st/oblt-ci-cd-stats. (though it's only accessible for Elasticians and the new TAV GH action won't be available until this PR gets merged) Our plan is to leverage the existing GitHub metadata and provide insights that are meaningful. We are at the moment with the migration stage, but definitely it's something we will invest effort so we can help to answer those kind of questions. |
That'll be cool to browse around, and yes perhaps we could make a dashboard from that data. Here is the beginnings of a replacement using the GH API and #!/bin/bash
branch=main
branch=test/action-tav
latestTavRun=$(gh run list -R elastic/apm-agent-nodejs -b "$branch" -w TAV -L 1 --json databaseId --jq '.[].databaseId')
gh api --paginate repos/elastic/apm-agent-nodejs/actions/runs/$latestTavRun/jobs \
| json -ga jobs \
| json -ga -e '
this.s = (new Date(this.completed_at) - new Date(this.started_at)) / 1000;
this.minSec = Math.floor(this.s/60) + "m" + (this.s%60).toString().padStart(2,"0") + "s"
' s minSec name \
| sort -nRunning that yields: |
Migrate TAV to run as GitHub actions when - a merge commit in the `main` branch - manually triggered TAV matrix is declared in the GH workflow hence no more .tav files to be maintained. We agreed recently that It will not run on PRs for now, if needed we can add that feature in a follow up, maybe using the smarter jenkins implementation if it still works.


What
Migrate TAV to run as GitHub actions when
mainbranchTAV matrix is declared in the GH workflow hence no more .tav files to be maintained.
Checklist
Caveats
We agreed recently that It will not run on PRs for now, if needed we can add that feature in a follow up, maybe using the smarter jenkins implementation if it still works.