From 16558f5d555c6072b0a15496689959b86796865c Mon Sep 17 00:00:00 2001 From: gbamparop Date: Fri, 5 Jul 2024 08:50:05 +0100 Subject: [PATCH 1/2] Enable LogsDB in tests --- x-pack/test/functional/apps/dataset_quality/config.ts | 8 ++++++++ .../functional/apps/observability_logs_explorer/config.ts | 8 ++++++++ .../functional/test_suites/observability/config.ts | 2 +- 3 files changed, 17 insertions(+), 1 deletion(-) diff --git a/x-pack/test/functional/apps/dataset_quality/config.ts b/x-pack/test/functional/apps/dataset_quality/config.ts index c7e72325d6c07..ec15a8032ec87 100644 --- a/x-pack/test/functional/apps/dataset_quality/config.ts +++ b/x-pack/test/functional/apps/dataset_quality/config.ts @@ -27,6 +27,14 @@ export default async function createTestConfig({ readConfigFile }: FtrConfigProv }); }, }, + esTestCluster: { + ...functionalConfig.get('esTestCluster'), + serverArgs: [ + ...functionalConfig.get('esTestCluster.serverArgs'), + // Enable LogsDB + 'cluster.logsdb.enabled=true', + ], + }, pageObjects, }; } diff --git a/x-pack/test/functional/apps/observability_logs_explorer/config.ts b/x-pack/test/functional/apps/observability_logs_explorer/config.ts index 0811f0e2a794e..498445c38c1b2 100644 --- a/x-pack/test/functional/apps/observability_logs_explorer/config.ts +++ b/x-pack/test/functional/apps/observability_logs_explorer/config.ts @@ -50,6 +50,14 @@ export default async function createTestConfig({ }); }, }, + esTestCluster: { + ...functionalConfig.get('esTestCluster'), + serverArgs: [ + ...functionalConfig.get('esTestCluster.serverArgs'), + // Enable LogsDB + 'cluster.logsdb.enabled=true', + ], + }, }; } diff --git a/x-pack/test_serverless/functional/test_suites/observability/config.ts b/x-pack/test_serverless/functional/test_suites/observability/config.ts index 2610af2a26149..ff69673f9928b 100644 --- a/x-pack/test_serverless/functional/test_suites/observability/config.ts +++ b/x-pack/test_serverless/functional/test_suites/observability/config.ts @@ -17,6 +17,6 @@ export default createTestConfig({ // include settings from project controller // https://github.com/elastic/project-controller/blob/main/internal/project/observability/config/elasticsearch.yml - esServerArgs: ['xpack.ml.dfa.enabled=false'], + esServerArgs: ['xpack.ml.dfa.enabled=false', 'cluster.logsdb.enabled=true'], kbnServerArgs: [], }); From 7320eb5b52bdbb237a8d66d01c9e72df7fea3a47 Mon Sep 17 00:00:00 2001 From: gbamparop Date: Fri, 5 Jul 2024 15:02:11 +0100 Subject: [PATCH 2/2] Update test config --- x-pack/test/api_integration/apis/logs_ui/config.ts | 8 ++++++++ .../test/dataset_quality_api_integration/common/config.ts | 5 +++++ x-pack/test/functional/apps/infra/config.ts | 8 ++++++++ 3 files changed, 21 insertions(+) diff --git a/x-pack/test/api_integration/apis/logs_ui/config.ts b/x-pack/test/api_integration/apis/logs_ui/config.ts index 5f335f116fefe..673878f27e261 100644 --- a/x-pack/test/api_integration/apis/logs_ui/config.ts +++ b/x-pack/test/api_integration/apis/logs_ui/config.ts @@ -13,5 +13,13 @@ export default async function ({ readConfigFile }: FtrConfigProviderContext) { return { ...baseIntegrationTestsConfig.getAll(), testFiles: [require.resolve('.')], + esTestCluster: { + ...baseIntegrationTestsConfig.get('esTestCluster'), + serverArgs: [ + ...baseIntegrationTestsConfig.get('esTestCluster.serverArgs'), + // Enable LogsDB + 'cluster.logsdb.enabled=true', + ], + }, }; } diff --git a/x-pack/test/dataset_quality_api_integration/common/config.ts b/x-pack/test/dataset_quality_api_integration/common/config.ts index e297d8eaf0354..2bc89f49bec32 100644 --- a/x-pack/test/dataset_quality_api_integration/common/config.ts +++ b/x-pack/test/dataset_quality_api_integration/common/config.ts @@ -153,6 +153,11 @@ export function createTestConfig( esTestCluster: { ...xPackAPITestsConfig.get('esTestCluster'), license, + serverArgs: [ + ...xPackAPITestsConfig.get('esTestCluster.serverArgs'), + // Enable LogsDB + 'cluster.logsdb.enabled=true', + ], }, kbnTestServer: { ...xPackAPITestsConfig.get('kbnTestServer'), diff --git a/x-pack/test/functional/apps/infra/config.ts b/x-pack/test/functional/apps/infra/config.ts index 21b2cca3589d7..78b455208b01a 100644 --- a/x-pack/test/functional/apps/infra/config.ts +++ b/x-pack/test/functional/apps/infra/config.ts @@ -20,5 +20,13 @@ export default async function ({ readConfigFile }: FtrConfigProviderContext) { `--xpack.infra.featureFlags.profilingEnabled=true`, ], }, + esTestCluster: { + ...functionalConfig.get('esTestCluster'), + serverArgs: [ + ...functionalConfig.get('esTestCluster.serverArgs'), + // Enable LogsDB + 'cluster.logsdb.enabled=true', + ], + }, }; }