Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main' into 170497-discover-esq…
Browse files Browse the repository at this point in the history
…uery-scopeselect
  • Loading branch information
Zacqary committed Nov 30, 2023
2 parents 1c9a672 + ab5ff9c commit 12c7a13
Show file tree
Hide file tree
Showing 3,711 changed files with 95,421 additions and 33,328 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
15 changes: 13 additions & 2 deletions .buildkite/ftr_configs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ disabled:
- x-pack/test/api_integration/config.ts
- x-pack/test/fleet_api_integration/config.base.ts
- x-pack/test/security_solution_api_integration/config/ess/config.base.ts
- x-pack/test/security_solution_api_integration/config/ess/config.base.basic.ts
- x-pack/test/security_solution_api_integration/config/serverless/config.base.ts
- x-pack/test/security_solution_api_integration/config/serverless/config.base.essentials.ts
- x-pack/test/security_solution_endpoint/config.base.ts
- x-pack/test/security_solution_endpoint_api_int/config.base.ts

Expand Down Expand Up @@ -156,7 +158,9 @@ enabled:
- test/server_integration/http/ssl_with_p12/config.js
- test/server_integration/http/ssl/config.js
- test/ui_capabilities/newsfeed_err/config.ts
- x-pack/test/accessibility/config.ts
- x-pack/test/accessibility/apps/group1/config.ts
- x-pack/test/accessibility/apps/group2/config.ts
- x-pack/test/accessibility/apps/group3/config.ts
- x-pack/test/localization/config.ja_jp.ts
- x-pack/test/localization/config.fr_fr.ts
- x-pack/test/localization/config.zh_cn.ts
Expand Down Expand Up @@ -329,7 +333,6 @@ enabled:
- x-pack/test/kubernetes_security/basic/config.ts
- x-pack/test/licensing_plugin/config.public.ts
- x-pack/test/licensing_plugin/config.ts
- x-pack/test/lists_api_integration/security_and_spaces/config.ts
- x-pack/test/monitoring_api_integration/config.ts
- x-pack/test/observability_api_integration/basic/config.ts
- x-pack/test/observability_api_integration/trial/config.ts
Expand Down Expand Up @@ -486,3 +489,11 @@ enabled:
- x-pack/test/security_solution_api_integration/test_suites/detections_response/default_license/user_roles/configs/ess.config.ts
- x-pack/test/security_solution_api_integration/test_suites/detections_response/default_license/telemetry/configs/serverless.config.ts
- x-pack/test/security_solution_api_integration/test_suites/detections_response/default_license/telemetry/configs/ess.config.ts
- x-pack/test/security_solution_api_integration/test_suites/detections_response/basic_essentials_license/detection_engine/configs/serverless.config.ts
- x-pack/test/security_solution_api_integration/test_suites/detections_response/basic_essentials_license/detection_engine/configs/ess.config.ts
- x-pack/test/security_solution_api_integration/test_suites/lists_and_exception_lists/default_license/exception_lists_items/configs/serverless.config.ts
- x-pack/test/security_solution_api_integration/test_suites/lists_and_exception_lists/default_license/exception_lists_items/configs/ess.config.ts
- x-pack/test/security_solution_api_integration/test_suites/lists_and_exception_lists/default_license/lists_items/configs/serverless.config.ts
- x-pack/test/security_solution_api_integration/test_suites/lists_and_exception_lists/default_license/lists_items/configs/ess.config.ts


4 changes: 2 additions & 2 deletions .buildkite/pipeline-utils/ci-stats/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ export class CiStatsClient {
headers: this.defaultHeaders,
});
} catch (error) {
console.error('CI Stats request error:', error);
console.error('CI Stats request error:', error?.response?.data?.message);

if (attempt < maxAttempts) {
const sec = attempt * 3;
Expand All @@ -210,7 +210,7 @@ export class CiStatsClient {
continue;
}

throw error;
throw new Error('Failed to connect to CI Stats.');
}
}
}
Expand Down
10 changes: 9 additions & 1 deletion .buildkite/pipeline-utils/ci-stats/on_complete.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,15 @@ export async function onComplete() {

const report = await ciStats.getPrReport(process.env.CI_STATS_BUILD_ID);
if (report?.md) {
buildkite.setMetadata('pr_comment:ci_stats_report:body', report.md);
// buildkite has a metadata size limit of 100kb, so we only add this, if it's small enough
if (new Blob([report.md]).size < 100000) {
buildkite.setMetadata('pr_comment:ci_stats_report:body', report.md);
} else {
buildkite.setMetadata(
'pr_comment:ci_stats_report:body',
'The CI Stats report is too large to be displayed here, check out the CI build annotation for this information.'
);
}

const annotationType = report?.success ? 'info' : 'error';
buildkite.setAnnotation('ci-stats-report', annotationType, report.md);
Expand Down
2 changes: 1 addition & 1 deletion .buildkite/pipelines/artifacts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ steps:
- exit_status: '*'
limit: 1

- command: KIBANA_DOCKER_CONTEXT=ubi9 .buildkite/scripts/steps/artifacts/docker_context.sh
- command: KIBANA_DOCKER_CONTEXT=ubi .buildkite/scripts/steps/artifacts/docker_context.sh
label: 'Docker Context Verification'
agents:
queue: n2-2
Expand Down
64 changes: 60 additions & 4 deletions .buildkite/pipelines/es_serverless/verify_es_serverless_image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,12 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_serverless.sh
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:run:serverless
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-serverless-security-cypress
MSG: "--- Security Serverless Cypress Tests"
label: 'Serverless Security Cypress Tests'
if: "build.env('SKIP_CYPRESS') != '1' && build.env('SKIP_CYPRESS') != 'true'"
agents:
Expand All @@ -69,7 +74,12 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_serverless_explore.sh
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:explore:run:serverless
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Explore - Security Solution Cypress Tests"
label: 'Serverless Explore - Security Solution Cypress Tests'
if: "build.env('SKIP_CYPRESS') != '1' && build.env('SKIP_CYPRESS') != 'true'"
agents:
Expand All @@ -82,7 +92,12 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_serverless_investigations.sh
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:investigations:run:serverless
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Investigations Cypress Tests on Serverless"
label: 'Serverless Investigations - Security Solution Cypress Tests'
if: "build.env('SKIP_CYPRESS') != '1' && build.env('SKIP_CYPRESS') != 'true'"
agents:
Expand All @@ -95,7 +110,48 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/defend_workflows_serverless.sh
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:rule_management:run:serverless
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Rule Management Cypress Tests on Serverless"
label: 'Serverless Rule Management - Security Solution Cypress Tests'
if: "build.env('SKIP_CYPRESS') != '1' && build.env('SKIP_CYPRESS') != 'true'"
agents:
queue: n2-4-spot
depends_on: build
timeout_in_minutes: 60
parallelism: 8
retry:
automatic:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:rule_management:prebuilt_rules:run:serverless
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Rule Management - Prebuilt Rules - Cypress Tests on Serverless"
label: 'Serverless Rule Management - Prebuilt Rules - Security Solution Cypress Tests'
if: "build.env('SKIP_CYPRESS') != '1' && build.env('SKIP_CYPRESS') != 'true'"
agents:
queue: n2-4-spot
depends_on: build
timeout_in_minutes: 60
parallelism: 6
retry:
automatic:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:dw:serverless:run
ROOT_DIR: x-pack/plugins/security_solution
JOB_TITLE: kibana-defend-workflows-serverless-cypress
MSG: "--- Defend Workflows Cypress tests on Serverless"
label: 'Defend Workflows Cypress Tests on Serverless'
if: "build.env('SKIP_CYPRESS') != '1' && build.env('SKIP_CYPRESS') != 'true'"
agents:
Expand Down
135 changes: 124 additions & 11 deletions .buildkite/pipelines/on_merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,12 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_serverless.sh
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:run:serverless
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-serverless-security-cypress
MSG: "--- Security Serverless Cypress Tests"
label: 'Serverless Security Cypress Tests'
agents:
queue: n2-4-spot
Expand All @@ -91,8 +96,13 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_serverless_explore.sh
label: 'Serverless Explore - Security Solution Cypress Tests'
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:explore:run:serverless
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Serverless Explore - Security Cypress Tests"
label: 'Serverless Explore - Security Cypress Tests'
agents:
queue: n2-4-spot
depends_on: build
Expand All @@ -103,8 +113,30 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_serverless_investigations.sh
label: 'Serverless Investigations - Security Solution Cypress Tests'
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:investigations:run:serverless
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Serverless Investigations - Security Cypress Tests"
label: 'Serverless Investigations - Security Cypress Tests'
agents:
queue: n2-4-spot
depends_on: build
timeout_in_minutes: 60
parallelism: 8
retry:
automatic:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:rule_management:run:serverless
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Serverless Rule Management - Security Cypress Tests "
label: 'Serverless Rule Management - Security Cypress Tests'
agents:
queue: n2-4-spot
depends_on: build
Expand All @@ -115,7 +147,63 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_solution.sh
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:rule_management:prebuilt_rules:run:serverless
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Rule Management - Prebuilt Rules - Security Cypress Tests"
label: 'Rule Management - Prebuilt Rules - Security Cypress Tests'
agents:
queue: n2-4-spot
depends_on: build
timeout_in_minutes: 60
parallelism: 6
retry:
automatic:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:rule_management:run:ess
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Rule Management - Security Solution Cypress Tests"
label: 'Rule Management - Security Solution Cypress Tests'
agents:
queue: n2-4-spot
depends_on: build
timeout_in_minutes: 60
parallelism: 8
retry:
automatic:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:rule_management:prebuilt_rules:run:ess
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Rule Management - Prebuilt Rules - Security Solution Cypress Tests"
label: 'Rule Management - Prebuilt Rules - Security Solution Cypress Tests'
agents:
queue: n2-4-spot
depends_on: build
timeout_in_minutes: 60
parallelism: 6
retry:
automatic:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:run:ess
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Security Solution Cypress tests (Chrome)"
label: 'Security Solution Cypress Tests'
agents:
queue: n2-4-spot
Expand All @@ -127,7 +215,12 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_solution_explore.sh
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:explore:run:ess
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Explore Cypress Tests on Security Solution"
label: 'Explore - Security Solution Cypress Tests'
agents:
queue: n2-4-spot
Expand All @@ -139,7 +232,12 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/security_solution_investigations.sh
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:investigations:run:ess
ROOT_DIR: x-pack/test/security_solution_cypress
JOB_TITLE: kibana-security-solution-chrome
MSG: "--- Investigations - Security Solution Cypress Tests"
label: 'Investigations - Security Solution Cypress Tests'
agents:
queue: n2-4-spot
Expand All @@ -151,7 +249,12 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/defend_workflows.sh
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:dw:run
ROOT_DIR: x-pack/plugins/security_solution
JOB_TITLE: kibana-defend-workflows-cypress
MSG: "--- Defend Workflows Cypress tests"
label: 'Defend Workflows Cypress Tests'
agents:
queue: n2-4-virt
Expand All @@ -163,7 +266,12 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/defend_workflows_serverless.sh
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:dw:serverless:run
ROOT_DIR: x-pack/plugins/security_solution
JOB_TITLE: kibana-defend-workflows-serverless-cypress
MSG: "--- Defend Workflows Cypress tests on Serverless"
label: 'Defend Workflows Cypress Tests on Serverless'
agents:
queue: n2-4-virt
Expand All @@ -175,7 +283,12 @@ steps:
- exit_status: '*'
limit: 1

- command: .buildkite/scripts/steps/functional/threat_intelligence.sh
- command: .buildkite/scripts/steps/functional/security_cypress_exec.sh
env:
TARGET: cypress:run
ROOT_DIR: x-pack/plugins/threat_intelligence
JOB_TITLE: kibana-threat-intelligence-chrome
MSG: "--- Threat Intelligence Cypress tests (Chrome)"
label: 'Threat Intelligence Cypress Tests'
agents:
queue: n2-4-spot
Expand Down
Loading

0 comments on commit 12c7a13

Please sign in to comment.