Commit graph

77 commits

Author SHA1 Message Date
Dimitrios Liappis
26d4179d88
Remove Debian 10 from CI (#16300) (#16328)
This commit removes Debian 10 (Buster) which is EOL
since July 1 2024[^1] from CI.

Relates https://github.com/elastic/ingest-dev/issues/2872
2024-07-15 17:54:39 +03:00
github-actions[bot]
7351c5c590
Remove CentOS 7 from CI (#16293) (#16297)
CentOS 7 is EOL since June 30 2024[^1]. All repositories and mirrors are
now unreachable.

This commit removes CentOS 7 from CI jobs using it.

Relates https://github.com/elastic/ingest-dev/issues/3520

[^1]: https://www.redhat.com/en/topics/linux/centos-linux-eol

(cherry picked from commit db06ec415a)

Co-authored-by: Dimitrios Liappis <dimitrios.liappis@gmail.com>
2024-07-04 17:17:21 +03:00
github-actions[bot]
9f71e03312
Add retries to aarch64 CI pipeline (#16271) (#16272)
Add retries in the aarch64 CI pipeline to reduce noise from transient
network failures.

Closes https://github.com/elastic/ingest-dev/issues/3510

(cherry picked from commit 7080ec5427)

Co-authored-by: Dimitrios Liappis <dimitrios.liappis@gmail.com>
2024-07-01 14:31:11 +03:00
Mashhur
4a379be6d5
Fix the git branch check for snyk bk jobs (#16062)
* Replace 'git show-ref' with 'git rev-parse' to fix the issue where show-ref is not working as expected.
* Use git checkout instead 'git rev-parse'.
* Apply prune dependencies recommended for big projects (like we have multi gradle projects) by Snyk.
* Apply prune repeated dependency option directly to snyk monitor.
* Avoid the exit, continue scanning to the end.
* Remove the debugging.
2024-04-08 11:34:26 +01:00
Dimitrios Liappis
c0c213d17e
Split java/ruby unit test steps on Windows (#15888)
As a follow up to #15861 this commit splits the current unit tests step
for the Windows JDK matrix pipeline to two that run
Java and Ruby unit tests separately.

Closes https://github.com/elastic/logstash/issues/15566
2024-03-11 09:27:11 +02:00
Andres Rodriguez
8eb08e1382
Add Alma 8, Alma 9, and Rocky Linux 9 to the JDK matrix (#15941) 2024-02-13 11:01:21 -05:00
Dimitrios Liappis
2fc3f4c21f
Add retries to acceptance/docker steps in BK (#15901)
Similarly to #15874, this commit adds retries
to another group, the acceptance/docker to reduce
build noise from transient issues.
2024-02-06 15:10:13 +02:00
Dimitrios Liappis
fedcf58c48
Add Debian 12 to CI (#15895)
This commit adds Debian 12 (Bookworm) to the
Linux JDK matrix pipeline and Compat Phase of the
exhaustive pipeline respectively.

Relates https://github.com/elastic/ingest-dev/issues/2871
2024-02-05 18:49:30 +02:00
Dimitrios Liappis
8ac55184b8
Allow running Java+Ruby tests on Windows separately (#15861)
This commit allows separate running of Java and Ruby tests on Windows i.e. the same way as we currently do on unix (unit_tests.sh) via a cli argument.
If no argument has been supplied, both tests are run (as it does now).

The wrapper script is also rewritten from old batch style script to Powershell.

This work allows us to split the existing Windows CI job in a subsequent PR to separate steps, as we currently do on Linux.

Relates: https://github.com/elastic/logstash/issues/15566
2024-02-01 10:04:25 +02:00
Dimitrios Liappis
3b747d86b8
Add retries to JDK matrix pipeline steps (#15877)
This commit adds retries to the steps of the Linux + Windows JDK matrix
pipeline steps to avoid notification noise due to transient network
errors.
2024-01-30 18:02:57 +02:00
Dimitrios Liappis
88a32cca81
Add BK retries to exhaustive/compat steps (#15874)
As a follow up to #15787 we also add Buildkite retries for the
exhaustive pipeline / compatibility group steps to prevent
failures due to flakiness.
2024-01-30 14:33:33 +02:00
Dimitrios Liappis
5ee75803f8
Scheduled runs of exhaustive and aarch64 pipelines (#15850)
This commit adds a schedule to run the exhaustive pipeline
(biweekly, every other Wednesday @2AM UTC) and the aarch64
(weekly, every Monday@2AM UTC).

Closes https://github.com/elastic/ingest-dev/issues/2852
2024-01-28 19:30:02 +02:00
Dimitrios Liappis
3f5b44a1ad
Remove Ubuntu 18.04 from CI jobs (#15855)
Relates https://github.com/elastic/ingest-dev/issues/2849
2024-01-26 17:14:41 +02:00
Dimitrios Liappis
0d808ed708
Retries for serverless-integration-testing pipeline (#15851)
This commit adds (up to 3) retries for all steps of the `serverless-integration-testing`
pipeline as a stop-gap measure to prevent network related transient failures.
2024-01-25 17:24:00 +02:00
Dimitrios Liappis
c5cb1fe2ed
Annotate successful DRA builds with summary URL (#15820)
This commit makes the generated DRA URL easily accessible via
a Buildkite annotation.

Closes https://github.com/elastic/ingest-dev/issues/2608
2024-01-22 16:37:18 +02:00
Pavel Zorin
2c83a52380
[CI] Send Java and ruby tests to sonarqube simultaneously (#15810)
* Ruby code coverage with SimpleCov json formatter

* [CI] Send Java and ruby tests to sonarqube simultaneously

* Enabled COVERAGE for ruby tests

* Enabled COVERAGE for ruby tests

* Enabled COVERAGE for ruby tests

* Enabled COVERAGE for ruby tests

* Enabled COVERAGE for ruby tests

* Added compiled classes to artifacts

* Test change

* Removed test changes

* Returned back ENABLE_SONARQUBE condition

* Removed debug line

* Diable Ruby coverage if ENABLE_SONARQUBE is not true

* Run sonar scan on pull requests and onn push to main

* Run sonar can on release branches
2024-01-17 19:04:37 +00:00
Dimitrios Liappis
16c4d8827e
Enable packaging tests in exhaustive pipeline (#15781)
This commit adds the packaging tests (that were refactored in #15696
to not rely on Vagrant) in a new "acceptance" group.

Relates: https://github.com/elastic/ingest-dev/issues/1722
2024-01-12 17:52:06 +02:00
Dimitrios Liappis
fca1fccb66
Add Docker acceptance to exhaustive BK pipeline (#15748)
This commit adds the Docker acceptance tests in the acceptance phase
of the exhaustive tests pipeline.

- Relates: https://github.com/elastic/ingest-dev/issues/1722
2024-01-12 09:02:45 +02:00
Dimitrios Liappis
739e8a3ef0
Add retries to PR pipeline steps (#15787)
There is occasional flakiness mainly with IT tests requiring us to
manually retry such failures when we raise PR (or the first
group of the exhaustive suite, which runs the same steps).

This commit adds up to 3 retries for all the steps of the PR
pipeline.
2024-01-11 15:48:45 +02:00
Dimitrios Liappis
c8726b79f3
Run BK exhaustive pipeline when code is pushed (#15738)
This commit enables running the exhaustive tests Buildkite pipeline
(i.e. the equivalent to the `main` Jenkins tests) ; the trigger is
code events, i.e. direct pushes, merge commits and creation of new branches.

CI is skipped if changes are only related to files under `docs/`.
2024-01-10 10:18:19 +02:00
Dimitrios Liappis
286088915f
JUnit result annotation for Buildkite PR jobs (#15741)
This commit adds annotations for Java unit tests (in the pull request pipeline) helping
identify failing unit tests quickly.
2024-01-04 17:21:07 +02:00
Andrea Selva
2be661b9bc
Re-enable json filter and netflow codec plugins (#15722)
- Re-enabled logstash-filter-json and logstash-codec-netflow plugins into the test_plugins BK pipeline.
- Moved codecs tier2 to be executed in separata VM.
- Commented plugin logstash-codec-collectd till is fixed
2024-01-02 17:20:28 +01:00
Dimitrios Liappis
a8b64a32e9
Skip input step when triggering JDK matrix jobs (#15733)
PR#15729 missed the input step. As a result when the job is triggered
the steps are executed, but the pause icon still shows in the job
requiring manual unblock[^1]

This commit also skips the input step when the job is triggered from
the scheduler pipeline.

[^1] https://buildkite.com/elastic/logstash-linux-jdk-matrix-pipeline/builds/86
2024-01-02 13:06:03 +02:00
Dimitrios Liappis
82ac474b13
Don't block triggered JDK matrix Buildkite jobs (#15729)
The recent PRs #15668 and #15705 refactored jobs with a custom schedule
to leverage a centralized trigger pipeline.

An unexpected sideffect of this is that the conditional for the wait
step doesn't work anymore.

This commit skips the wait step when the JDK matrix pipelines get triggered
from another pipeline.
2024-01-02 11:29:52 +02:00
Dimitrios Liappis
9538338abb
[ci] Add testing phase to exhaustive tests suite (#15711)
This is the second part of the migration of the exhaustive/main
Jenkins Job to Buildkite. So far we've migrated the "compatibility
phase" and this commit adds the "testing phase"[^1], which is essentially
the same amount of tests that we ran on PR jobs.

Relates https://github.com/elastic/ingest-dev/issues/1722
Depends https://github.com/elastic/logstash/pull/15708

[^1]: For more details, refer to the sequence diagram in https://github.com/elastic/ingest-dev/issues/1722#issuecomment-1824378635
2023-12-21 09:42:14 +02:00
Mashhur
0049717394
So far we are practicing Snyk scan of docker images. Now we can comment docker scan logic to address collected issues later with more experiements. (#15702) 2023-12-20 10:51:20 -08:00
Dimitrios Liappis
03d7b59f2a
[ci] Reusable unit + IT test steps for Buildkite (#15708)
This commit is a pre-requisite for adding unit + IT tests in a
dedicated phase of the Exhaustive tests pipeline.

It refactors the tests currently used by PR jobs, so that they become
reusable.
2023-12-20 18:22:09 +02:00
Dimitrios Liappis
06ceef8e13
[ci] Allow schedule to trigger several pipelines (#15703)
This commit enhances the functionality introduced in #15668 and #15700
by allowing a single Buildkite scheduling job to trigger several
pipelines, in addition to multiple branches which it already does.

We rename the env var PIPELINE_TO_TRIGGER to PIPELINES_TO_TRIGGER
which now supports comma separate values.

This enhancement can be useful for pipelines like JDK matrix which
have variants (Linux and Windows) that we want to trigger with a single
scheduling job, thus reducing unnecessary entries in catalog-info.
2023-12-20 10:22:46 +02:00
Dimitrios Liappis
42497edebb
Bug fix for trigger pipeline Buildkite pipeline (#15700)
This commit fixes a few bugs introduced in #15668 related to paths for
the calling script. We also stop limiting the execution only from the
main branch (to facilitate e.g. tests from PRs) and, finally, remove
the async clause, which is not needed, since by default BK steps are
run in parallel.
2023-12-19 13:33:46 +02:00
Dimitrios Liappis
c2eaecce8e
[ci] Remove hardcoded branches from DRA schedule (#15668)
This commit is the first making use of #15627 to remove hard coded
branches for the DRA Snapshot build schedule.

With this pattern, we will only need to keep `ci/branches.json` up to date,
as versions evolve, and not need to update/maintain hard coded branches
in `catalog-info.yaml` anymore.

Once this is verified working, we'll add a corresponding schedule
pipeline (in `catalog.info`) for the JDK matrix job.

Relates: https://github.com/elastic/ingest-dev/issues/2664
2023-12-19 11:42:28 +02:00
Dimitrios Liappis
f062fef603
[ci] Add Java 21 option for multi JDK CI pipeline (#15691)
Now that CI VM images are pre-provisioned with various flavors of
Java 21, we add the option for the corresponding CI job.
Adoptium 17 remains the default pre-selected option.

Relates https://github.com/elastic/ci-agent-images/pull/463
2023-12-18 16:56:48 +02:00
Andrea Selva
241c03274c
Avoid to run integration tests while testing all supported plugin (#15511)
Update the test_plugins pipeline script to execute only the unit tests.
Use the vendored JRuby in every Ruby related duty, such as running `bundler` and `gem`.
Temporarily comments plugins that has needs to be fixed and already fails on  their Travis CI.
Executes the testing of input tier1 plugins in VM instead of Buildkite agent.
2023-12-11 10:11:03 +01:00
Dimitrios Liappis
a26b1d399f
[ci] Skip Logstash PR checks when docs change (#15650)
Changes made under `docs/` are unrelated to the PR tests triggered from
this repo[^1]

This commit skips regular PR tests when changes are made (only) under the `docs/` directory.

Note that the current docs-specific Jenkins Job is getting migrated
at an org level[^2] to Buildkite, and this change will be merged soon.

Relates:

- https://github.com/elastic/ingest-dev/issues/2703

[^1]: via `.buildkite/pull_requests_pipeline.yml`
[^2]: https://github.com/elastic/docs/blob/master/.buildkite/pull-requests.org-wide.json
2023-12-04 19:14:57 +02:00
Dimitrios Liappis
d42b938f81
[ci] Compatibility tests for Exhaustive suite (#15641)
This commit adds the compatibility tier for the Exhaustive tests suite.
Specifically, we introduce two new groups (running in parallel) for Linux and Windows compat tests.
Linux picks one OS per family from [^] and likewise Windows one of the three available choices from the same file.

We also support manual override, if user chooses to, by setting `LINUX_OS` or `WINDOWS_OS` as env vars in the Buildkite build prompt (in this case there is no randomization, and only one OS can be defined for Linux and Windows respectively).

For example:
```
LINUX_OS=rhel-9
WINDOWS_OS=windows=216
```

Relates:

- https://github.com/elastic/ingest-dev/issues/1722

[^1]: 4d6bd955e6/.buildkite/scripts/common/vm-images.json
2023-11-30 20:28:19 +02:00
Dimitrios Liappis
6446bba962
[ci] Switch to Adoptium distro for JDK 11 (#15629)
AdoptOpenJDK is nowadays Adoptium, so we replace it in favor of
the latter which is actively maintained.

Relates https://github.com/elastic/logstash/pull/15628
2023-11-29 11:37:27 +02:00
Dimitrios Liappis
f0019bf33c
[ci] Fix scheduled JDK matrix CI jobs (#15623)
This commit fixes failed scheduled JDK matrix CI jobs, that
can't access the default values for the OS and JDK from the input
steps, as observed in [^1] and [^2].

[^1] https://buildkite.com/elastic/logstash-linux-jdk-matrix-pipeline/builds/53#018c1371-b760-4c28-9203-340c0a1df150
[^2]: https://buildkite.com/elastic/logstash-windows-jdk-matrix-pipeline/builds/35#018c1371-b72e-48b4-b707-ce103eb6039c
2023-11-28 16:00:32 +02:00
Mashhur
1e65f53d68
Use proper BK agent and simplify some operations in Snyk report pipeline. (#15610)
* Use Java installed BK agent and remove unnecessary git clone operation since repo is already cloned.

* Switch back to normal VM since Logstash BK agent doesn't support docker operations.
2023-11-27 09:31:25 -08:00
Dimitrios Liappis
db50983ab5
[ci] Initial Exhaustive tests Buildkite pipeline (#15607)
This commit adds a skeleton Buildkite pipeline for the Exhaustive tests
suite.
2023-11-27 11:06:19 +02:00
Dimitrios Liappis
e259e04e53
[ci] Use GCP prod image for Linux JDK matrix job (#15600)
So far we've been using images from the -qa GCP image project throughput
the development of the Logstash Linux JDK matrix pipeline for quicker
iteration.

As we have scheduled weekly builds of those images that promote to
prod[^1] we can now switch to the prod version of the GCP images.

[^1]: https://buildkite.com/elastic/ci-vm-images/builds/2888

Relates https://github.com/elastic/ingest-dev/issues/1725
2023-11-20 17:27:04 +02:00
Dimitrios Liappis
8fa3bd0d7f
[ci] Support amazonlinux for JDK matrix pipeline (#15595)
The last part of the Logstash JDK matrix CI migration from Jenkins to
Buildkite is AmazonLinux 2023.

While we have a working image[^1], this is the only step that requires
a agent that runs on AWS.

This commit refactors the builder to support GCP or AWS agents depending
on the OS.

[^1]: https://github.com/elastic/ci-agent-images/pull/441
2023-11-20 11:32:47 +02:00
Dimitrios Liappis
cd01abb1c7
[ci] Add yaml language server to pipelines (#15590)
Add missing yaml-language-server definition to Buildkite pipeline files
(static and dynamic generated) for consistency and to ease spotting
errors with editors.
2023-11-15 17:47:15 +02:00
Dimitrios Liappis
ce63ea4a51
[ci] Fix image name for Rocky Linux 8 (#15584)
Fix typo for image name of Rocky Linux 8 for JDK matrix jobs.
2023-11-14 19:26:49 +02:00
Dimitrios Liappis
0ede19a0e1
[ci] JDK matrix Buildkite pipelines (pt 2/Windows) (#15563)
This commit adds JDK matrix Buildkite pipelines for
Windows 2022, 2019 and 2016.

It also makes the groups easier to read (on both Linux and Windows
pipelines) by removing the os-jdk prefix from the job labels.

`testDLQWriterFlusherRemovesExpiredSegmentWhenCurrentHeadSegmentIsEmpty`
fails on Windows Buildkite agents and it's a test issue tracked in
https://github.com/elastic/logstash/issues/15562.

Relates:

- https://github.com/elastic/logstash/pull/15539
- https://github.com/elastic/ingest-dev/issues/1725
2023-11-10 17:25:13 +02:00
Dimitrios Liappis
956bf483f2
[ci] JDK matrix Buildkite pipelines (part 1) (#15539)
This commit is the first part of the migration of JDK matrix tests
from Jenkins to Buildkite. There will be two separate pipelines, for
Linux and Windows.

Linux is currently limited to Ubuntu 22.04 and 20.04, but
additional operating systems will be added outside of the Logstash
repository seamlessly through additional VM images.

Steps are created dynamically and the underlying script is meant to be
common for Linux and Windows. Windows is currently a stub and
will be added in a follow up PR.

Relates:

- https://github.com/elastic/ingest-dev/issues/1725
- https://github.com/elastic/ci-agent-images/pull/424
2023-11-09 09:53:27 +02:00
Dimitrios Liappis
07147b3e40
[ci] Split JDK matrix pipelines per OS (#15534)
This commit splits the generic Buildkite pipelines introduced
in #15520 for JDK tests to separate pipelines for Linux and Windows.
2023-11-07 15:22:37 +02:00
Andres Rodriguez
cf71dae3ff
Add support to test unsupported plugins (#15526)
Add support to test unsupported plugins. Only enable input-rss for now.
2023-11-03 12:08:01 -04:00
Dimitrios Liappis
ccc41d76ff
[ci] Initial JDK matrix Buildkite pipeline (#15520)
This commit adds a skeleton Buildkite pipeline for the JDK matrix tests.

Relates:

- https://github.com/elastic/logstash/pull/15519
- https://github.com/elastic/ingest-dev/issues/1725
2023-11-02 17:51:50 +02:00
Dimitrios Liappis
c384190718
[ci] aarch64 Buildkite pipeline part 2 (#15473)
This commit is the follow up PR after #15466, which migrates away
the remaining aarch64 acceptance test Jenkins jobs to Buildkite.

Relates:

- #15466
- https://github.com/elastic/ingest-dev/issues/1724
2023-10-25 18:08:56 +03:00
Dimitrios Liappis
16da966290
[ci] re-enable Java unit tests on aarch64 pipeline (#15492)
PR#15466 skipped the Java unit tests as on the `main` and `8.11`
branches they attempted to run sonar scans (which are only meant to
run for PRs).

This commit re-enables the Java unit tests, taking advantage of #15486,
disabling the sonar scan part of the test suite.
2023-10-24 18:05:14 +03:00
Dimitrios Liappis
36656de4f0
[ci] aarch64 Buildkite pipeline part 1 (#15466)
This commit is the first part of migrating away the aarch64 Jenkins
jobs to Buildkite. It adds a group of exhaustive test steps in the
aarch64 pipeline.

The java unit tests are temporarily disabled as they run SonarQube
scans which need to be associated with pull requests.

Relates:

https://github.com/elastic/ingest-dev/issues/1724
2023-10-23 15:01:14 +03:00