feat: add a mage command to package system tests#27295
Merged
mdelapenya merged 5 commits intoelastic:masterfrom Aug 23, 2021
Merged
feat: add a mage command to package system tests#27295mdelapenya merged 5 commits intoelastic:masterfrom
mdelapenya merged 5 commits intoelastic:masterfrom
Conversation
Contributor
💚 Build Succeeded
Expand to view the summary
Build stats
Test stats 🧪
Trends 🧪💚 Flaky test reportTests succeeded. Expand to view the summary
Test stats 🧪
|
cachedout
approved these changes
Aug 18, 2021
jsoriano
approved these changes
Aug 19, 2021
Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co>
Contributor
Author
|
Waiting on @andrewkroh for final review 🙏 |
andrewkroh
approved these changes
Aug 20, 2021
Member
andrewkroh
left a comment
There was a problem hiding this comment.
I think it's missing an error check, but otherwise LGTM.
Contributor
Author
|
@jsoriano I'm gonna merge this one, but would like your help with the backports labels first: 7.x, 7.15 and 7.14? |
Member
I would say to backport this to 7.x and 7.15. |
mergify bot
pushed a commit
that referenced
this pull request
Aug 23, 2021
* feat: add a mage command to package system tests * chore: delegate prints to the caller * chore: do not keep writing tar file in memory * chore: update comment Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co> * chore: handle error while traversing the filesystem Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co> (cherry picked from commit 7f086e5)
mergify bot
pushed a commit
that referenced
this pull request
Aug 23, 2021
* feat: add a mage command to package system tests * chore: delegate prints to the caller * chore: do not keep writing tar file in memory * chore: update comment Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co> * chore: handle error while traversing the filesystem Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co> (cherry picked from commit 7f086e5)
6 tasks
mdelapenya
added a commit
that referenced
this pull request
Aug 24, 2021
* feat: add a mage command to package system tests * chore: delegate prints to the caller * chore: do not keep writing tar file in memory * chore: update comment Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co> * chore: handle error while traversing the filesystem Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co> (cherry picked from commit 7f086e5) Co-authored-by: Manuel de la Peña <mdelapenya@gmail.com>
mdelapenya
added a commit
that referenced
this pull request
Aug 24, 2021
* feat: add a mage command to package system tests * chore: delegate prints to the caller * chore: do not keep writing tar file in memory * chore: update comment Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co> * chore: handle error while traversing the filesystem Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co> (cherry picked from commit 7f086e5) Co-authored-by: Manuel de la Peña <mdelapenya@gmail.com>
6 tasks
Icedroid
pushed a commit
to Icedroid/beats
that referenced
this pull request
Nov 1, 2021
* feat: add a mage command to package system tests * chore: delegate prints to the caller * chore: do not keep writing tar file in memory * chore: update comment Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co> * chore: handle error while traversing the filesystem Co-authored-by: Jaime Soriano Pastor <jaime.soriano@elastic.co>
6 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
This PR adds a mage command to package the system tests results. This command is invoked in the CI in the same conditions that in the past.
The command is composed by:
mage packageSystemTestscommand, plugged into filebeat and metricbeat modules (both OSS and xpack flavours).Tarmethod under thecommonspackage, so that it's possible to compress a source directory using TAR+GZIP algorithms, and writing it to the build dir in the root directory of the Beats repository.Besides that, we are removing a python script that detected the path to the Python system-tests (used in the pipeline to store the folder name in a variable), and we are updating the Jenkins pipeline to call the new build system command instead of the previous script. To keep existing behaviour, that we could consider it wrong and would possible discuss about it in a follow-up issue, we are passing a new argument to the groovy method in the pipeline, representing the directory in which the Beat live (i.e. filebeat, x-pack/filebeat), so that it's possible to run the
magecommand in the right context.Why is it important?
In the past, the collection of the system tests results was done at the pipeline level, so developers were not able to reproduce them. With this new command now it's possible to collect them directly from the build system.
For debugging purpose, it will be possible to debug a CI worker, capturing it and executing this command, to verify if the files to be uploaded are there.
Checklist
CHANGELOG.next.asciidocorCHANGELOG-developer.next.asciidoc.How to test this PR locally
Expected behaviour: a TAR file in the root's
builddirectory named as the Beat will exist (i.e. ./build/system-tests-filebeat.tar.gz)Related issues
Use cases
Screenshots
Logs