From 082a12b618e7ecf7a8189c6bf8bbff31a2ada71a Mon Sep 17 00:00:00 2001 From: Olga Naidjonoka Date: Mon, 29 Apr 2024 15:29:34 +0300 Subject: [PATCH 1/5] updated filebeat pipeline --- .buildkite/filebeat/filebeat-pipeline.yml | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/.buildkite/filebeat/filebeat-pipeline.yml b/.buildkite/filebeat/filebeat-pipeline.yml index 053e8dbec419..57865accd17c 100644 --- a/.buildkite/filebeat/filebeat-pipeline.yml +++ b/.buildkite/filebeat/filebeat-pipeline.yml @@ -28,6 +28,7 @@ steps: steps: - label: ":ubuntu: Ubuntu Unit Tests" command: | + set -euo pipefail cd filebeat mage build unitTest retry: @@ -46,6 +47,7 @@ steps: - label: ":ubuntu: Ubuntu Go Integration Tests" command: | + set -euo pipefail cd filebeat mage goIntegTest retry: @@ -64,6 +66,7 @@ steps: - label: ":ubuntu: Ubuntu Python Integration Tests" command: | + set -euo pipefail cd filebeat mage pythonIntegTest retry: @@ -124,6 +127,8 @@ steps: - group: "Filebeat Extended Tests" key: "filebeat-extended-tests" + if: build.env("BUILDKITE_PULL_REQUEST") == "false" || build.env("GITHUB_PR_LABELS") =~ /.*(macOS|arm).*/ + steps: - label: ":mac: MacOS x64_64 Unit Tests" key: "macos-unit-tests-extended" @@ -144,9 +149,9 @@ steps: - "filebeat/build/*.json" notify: - github_commit_status: - context: "filebeat: Extended MacOS Unit Tests" + context: "filebeat: MacOS Unit Tests" - - label: ":mac: MacOS arm64 Unit Tests" + - label: ":mac: MacOS ARM Unit Tests" key: "macos-arm64-unit-tests-extended" if: build.env("BUILDKITE_PULL_REQUEST") == "false" || build.env("GITHUB_PR_LABELS") =~ /.*macOS.*/ command: | @@ -165,12 +170,13 @@ steps: - "filebeat/build/*.json" notify: - github_commit_status: - context: "filebeat: Extended MacOS ARM Unit Tests" + context: "filebeat: MacOS ARM Unit Tests" - label: ":linux: Ubuntu ARM Unit Tests" key: "extended-arm64-unit-test" if: build.env("BUILDKITE_PULL_REQUEST") == "false" || build.env("GITHUB_PR_LABELS") =~ /.*arm.*/ command: | + set -euo pipefail cd filebeat mage build unitTest retry: @@ -190,6 +196,7 @@ steps: - group: "Extended Windows Tests" key: "filebeat-extended-win-tests" if: build.env("BUILDKITE_PULL_REQUEST") == "false" || build.env("GITHUB_PR_LABELS") =~ /.*[Ww]indows.*/ + steps: - label: ":windows: Windows 2019 Unit Tests" key: "windows-extended-2019" @@ -267,6 +274,7 @@ steps: - label: ":linux: Packaging Linux" key: "packaging-linux" command: | + set -euo pipefail cd filebeat mage package agents: @@ -284,6 +292,7 @@ steps: - label: ":linux: Packaging ARM" key: "packaging-arm" command: | + set -euo pipefail cd filebeat mage package agents: From dce31adc572c039900d63cf0254560e988f643af Mon Sep 17 00:00:00 2001 From: Olga Naidjonoka Date: Tue, 30 Apr 2024 15:00:28 +0300 Subject: [PATCH 2/5] updated pre-command --- .buildkite/hooks/pre-command | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.buildkite/hooks/pre-command b/.buildkite/hooks/pre-command index 870ece78925e..b0061d6b7518 100644 --- a/.buildkite/hooks/pre-command +++ b/.buildkite/hooks/pre-command @@ -11,7 +11,7 @@ PRIVATE_CI_GCS_CREDENTIALS_PATH="kv/ci-shared/platform-ingest/gcp-platform-inges DOCKER_REGISTRY_SECRET_PATH="kv/ci-shared/platform-ingest/docker_registry_prod" GITHUB_TOKEN_VAULT_PATH="kv/ci-shared/platform-ingest/github_token" -if [[ "$BUILDKITE_PIPELINE_SLUG" == "beats" || "$BUILDKITE_PIPELINE_SLUG" == "filebeat" ]]; then +if [[ "$BUILDKITE_PIPELINE_SLUG" == "beats" ]]; then source .buildkite/env-scripts/env.sh if [[ -z "${GO_VERSION-""}" ]]; then export GO_VERSION=$(cat "${WORKSPACE}/.go-version") From 1d2fe80ab467e3c7f66fb8dc87c4f7de53944a00 Mon Sep 17 00:00:00 2001 From: Olga Naidjonoka Date: Wed, 1 May 2024 17:17:57 +0300 Subject: [PATCH 3/5] updated timeout for python tests --- dev-tools/mage/pytest.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev-tools/mage/pytest.go b/dev-tools/mage/pytest.go index 2506bc205c48..e96a00d00547 100644 --- a/dev-tools/mage/pytest.go +++ b/dev-tools/mage/pytest.go @@ -144,7 +144,7 @@ func PythonTest(params PythonTestArgs) error { } pytestOptions := []string{ - "--timeout=90", + "--timeout=120", "--durations=20", // Enable -x to stop at the first failing test // "-x", From 5e66f7f5f860af1e6a49c8800ac6ca56020fbf80 Mon Sep 17 00:00:00 2001 From: Olga Naidjonoka Date: Tue, 7 May 2024 12:05:16 +0300 Subject: [PATCH 4/5] restored original timeout --- dev-tools/mage/pytest.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev-tools/mage/pytest.go b/dev-tools/mage/pytest.go index e96a00d00547..2506bc205c48 100644 --- a/dev-tools/mage/pytest.go +++ b/dev-tools/mage/pytest.go @@ -144,7 +144,7 @@ func PythonTest(params PythonTestArgs) error { } pytestOptions := []string{ - "--timeout=120", + "--timeout=90", "--durations=20", // Enable -x to stop at the first failing test // "-x", From 662ab087bc97068c983dc43e565a00f99d850f70 Mon Sep 17 00:00:00 2001 From: Olga Naidjonoka Date: Wed, 8 May 2024 15:32:33 +0300 Subject: [PATCH 5/5] pr fixes --- .buildkite/filebeat/filebeat-pipeline.yml | 54 ++++++++++------------- 1 file changed, 24 insertions(+), 30 deletions(-) diff --git a/.buildkite/filebeat/filebeat-pipeline.yml b/.buildkite/filebeat/filebeat-pipeline.yml index 57865accd17c..187c6ded42c1 100644 --- a/.buildkite/filebeat/filebeat-pipeline.yml +++ b/.buildkite/filebeat/filebeat-pipeline.yml @@ -26,9 +26,8 @@ steps: - group: "Filebeat Mandatory Tests" key: "filebeat-mandatory-tests" steps: - - label: ":ubuntu: Ubuntu Unit Tests" + - label: ":ubuntu: Filebeat Unit Tests" command: | - set -euo pipefail cd filebeat mage build unitTest retry: @@ -43,11 +42,10 @@ steps: - "filebeat/build/*.json" notify: - github_commit_status: - context: "filebeat: Ubuntu Unit Tests" + context: "filebeat: Linux x86_64 Unit Tests" - - label: ":ubuntu: Ubuntu Go Integration Tests" + - label: ":ubuntu: Filebeat Go Integration Tests" command: | - set -euo pipefail cd filebeat mage goIntegTest retry: @@ -62,11 +60,10 @@ steps: - "filebeat/build/*.json" notify: - github_commit_status: - context: "filebeat: Ubuntu Go Integration Tests" + context: "filebeat: Filebeat Go Integration Tests" - - label: ":ubuntu: Ubuntu Python Integration Tests" + - label: ":ubuntu: Filebeat Python Integration Tests" command: | - set -euo pipefail cd filebeat mage pythonIntegTest retry: @@ -83,7 +80,7 @@ steps: - github_commit_status: context: "filebeat: Python Integration Tests" - - label: ":windows: Windows 2016 Unit Tests" + - label: ":windows: Filebeat Windows 2016 Unit Tests" key: "windows-2016-unit-tests" command: | Set-Location -Path filebeat @@ -104,7 +101,7 @@ steps: - github_commit_status: context: "filebeat: Windows 2016 Unit Tests" - - label: ":windows: Windows 2022 Unit Tests" + - label: ":windows: Filebeat Windows 2022 Unit Tests" key: "windows-2022-unit-tests" command: | Set-Location -Path filebeat @@ -130,7 +127,7 @@ steps: if: build.env("BUILDKITE_PULL_REQUEST") == "false" || build.env("GITHUB_PR_LABELS") =~ /.*(macOS|arm).*/ steps: - - label: ":mac: MacOS x64_64 Unit Tests" + - label: ":mac: Filebeat macOS x86_64 Unit Tests" key: "macos-unit-tests-extended" if: build.env("BUILDKITE_PULL_REQUEST") == "false" || build.env("GITHUB_PR_LABELS") =~ /.*macOS.*/ command: | @@ -149,9 +146,9 @@ steps: - "filebeat/build/*.json" notify: - github_commit_status: - context: "filebeat: MacOS Unit Tests" + context: "filebeat: macOS x86_64 Unit Tests" - - label: ":mac: MacOS ARM Unit Tests" + - label: ":mac: Filebeat macOS arm64 Unit Tests" key: "macos-arm64-unit-tests-extended" if: build.env("BUILDKITE_PULL_REQUEST") == "false" || build.env("GITHUB_PR_LABELS") =~ /.*macOS.*/ command: | @@ -170,13 +167,12 @@ steps: - "filebeat/build/*.json" notify: - github_commit_status: - context: "filebeat: MacOS ARM Unit Tests" + context: "filebeat: macOS arm64 Unit Tests" - - label: ":linux: Ubuntu ARM Unit Tests" + - label: ":linux: Filebeat arm64 Unit Tests" key: "extended-arm64-unit-test" if: build.env("BUILDKITE_PULL_REQUEST") == "false" || build.env("GITHUB_PR_LABELS") =~ /.*arm.*/ command: | - set -euo pipefail cd filebeat mage build unitTest retry: @@ -191,14 +187,14 @@ steps: - "filebeat/build/*.json" notify: - github_commit_status: - context: "filebeat: Extended Ubuntu ARM Unit Tests" + context: "filebeat: Linux arm64 Unit Tests" - - group: "Extended Windows Tests" + - group: "Filebeat Extended Windows Tests" key: "filebeat-extended-win-tests" if: build.env("BUILDKITE_PULL_REQUEST") == "false" || build.env("GITHUB_PR_LABELS") =~ /.*[Ww]indows.*/ steps: - - label: ":windows: Windows 2019 Unit Tests" + - label: ":windows: Filebeat Windows 2019 Unit Tests" key: "windows-extended-2019" command: | Set-Location -Path filebeat @@ -217,9 +213,9 @@ steps: - "filebeat/build/*.json" notify: - github_commit_status: - context: "filebeat: Extended Windows 2019 Unit Tests" + context: "filebeat: Windows 2019 Unit Tests" - - label: ":windows: Windows 11 Unit Tests" + - label: ":windows: Filebeat Windows 11 Unit Tests" key: "windows-extended-11" command: | Set-Location -Path filebeat @@ -238,9 +234,9 @@ steps: - "filebeat/build/*.json" notify: - github_commit_status: - context: "filebeat: Extended Windows 11 Unit Tests" + context: "filebeat: Windows 11 Unit Tests" - - label: ":windows: Windows 10 Unit Tests" + - label: ":windows: Filebeat Windows 10 Unit Tests" key: "windows-extended-10" command: | Set-Location -Path filebeat @@ -259,7 +255,7 @@ steps: - "filebeat/build/*.json" notify: - github_commit_status: - context: "filebeat: Extended Windows 10 Unit Tests" + context: "filebeat: Windows 10 Unit Tests" - wait: ~ # with PRs, we want to run packaging only if mandatory tests succeed @@ -271,10 +267,9 @@ steps: - group: "Filebeat Packaging" key: "packaging" steps: - - label: ":linux: Packaging Linux" + - label: ":linux: Filebeat Packaging Linux" key: "packaging-linux" command: | - set -euo pipefail cd filebeat mage package agents: @@ -287,12 +282,11 @@ steps: PLATFORMS: "+all linux/amd64 linux/arm64 windows/amd64 darwin/amd64 darwin/arm64" notify: - github_commit_status: - context: "filebeat: Packaging" + context: "filebeat: Packaging Linux" - - label: ":linux: Packaging ARM" + - label: ":linux: Filebeat Packaging arm64" key: "packaging-arm" command: | - set -euo pipefail cd filebeat mage package agents: @@ -304,4 +298,4 @@ steps: PACKAGES: "docker" notify: - github_commit_status: - context: "filebeat: Packaging ARM" + context: "filebeat: Packaging arm64"