Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -25,17 +25,27 @@ interface CreateTestConfigOptions<T> {
indexRefreshInterval?: string | false;
}

// include settings from elasticsearch controller
// These args replicate the MKI setup from the elasticsearch controller:
// https://github.com/elastic/elasticsearch-controller/blob/main/helm/values.yaml
//
// ⚠️ Tests targeting these configs run against MKI. Adding a server arg here may allow
// tests to pass on Kibana CI but will cause failures on MKI if it is not yet supported there.
// If your test needs a feature flag, create a config under feature_flag_configs/ using
// createServerlessFeatureFlagTestConfig from feature_flag.serverless.config.base.ts.
const esServerArgsFromController = {
es: [],
oblt: ['xpack.apm_data.enabled=true'],
security: ['xpack.security.authc.api_key.cache.max_keys=70000'],
workplaceai: [],
};

// include settings from kibana controller
// These args replicate the MKI setup from the kibana controller:
// https://github.com/elastic/kibana-controller/blob/main/internal/controllers/kibana/config/config_settings.go
//
// ⚠️ Tests targeting these configs run against MKI. Adding a server arg here may allow
// tests to pass on Kibana CI but will cause failures on MKI if it is not yet supported there.
// If your test needs a feature flag, create a config under feature_flag_configs/ using
// createServerlessFeatureFlagTestConfig from feature_flag.serverless.config.base.ts.
const kbnServerArgsFromController = {
es: [
// useful for testing (also enabled in MKI QA)
Expand All @@ -60,8 +70,10 @@ export function createServerlessTestConfig<T extends DeploymentAgnosticCommonSer
return async ({ readConfigFile }: FtrConfigProviderContext): Promise<Config> => {
if (options.esServerArgs || options.kbnServerArgs) {
throw new Error(
`FTR doesn't provision custom ES/Kibana server arguments into the serverless project on MKI.
It may lead to unexpected test failures on Cloud. Please contact #appex-qa.`
`Deployment-agnostic configs run unchanged on MKI. Custom ES/Kibana server args passed here
Copy link
Copy Markdown
Member Author

@csr csr Mar 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The runtime error message is now less cryptic and more action-oriented.

won't be set on MKI and will cause unexpected test failures on Cloud.
If your test needs a feature flag, create a config under feature_flag_configs/ using
createServerlessFeatureFlagTestConfig from feature_flag.serverless.config.base.ts.`
);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,10 @@ export function createStatefulTestConfig<T extends DeploymentAgnosticCommonServi
return async ({ readConfigFile }: FtrConfigProviderContext) => {
if (options.esServerArgs || options.kbnServerArgs) {
throw new Error(
`FTR doesn't provision custom ES/Kibana server arguments into the ESS deployment.
It may lead to unexpected test failures on Cloud. Please contact #appex-qa.`
`Deployment-agnostic configs run unchanged on ECH (Elastic Cloud). Custom ES/Kibana server args passed here
won't be set on ECH and will cause unexpected test failures.
If your test needs a feature flag, create a config under feature_flag_configs/ using
createStatefulFeatureFlagTestConfig from feature_flag.stateful.config.base.ts.`
);
}

Expand Down Expand Up @@ -99,6 +101,8 @@ export function createStatefulTestConfig<T extends DeploymentAgnosticCommonServi
exclude: [...(options.suiteTags?.exclude || []), 'skipStateful'],
},

// ⚠️ Do not add server args here to make tests pass as they won't be set on ECH (Elastic Cloud Hosted).
// If your test needs a feature flag, use createStatefulFeatureFlagTestConfig (feature_flag_configs/).
esTestCluster: {
...xPackAPITestsConfig.get('esTestCluster'),
serverArgs: [
Expand All @@ -123,6 +127,8 @@ export function createStatefulTestConfig<T extends DeploymentAgnosticCommonServi
path.resolve(REPO_ROOT, STATEFUL_ROLES_ROOT_PATH, 'roles.yml'),
],
},
// ⚠️ Do not add server args here to make tests pass as they won't be set on ECH (Elastic Cloud Hosted).
// If your test needs a feature flag, use createStatefulFeatureFlagTestConfig (feature_flag_configs/).
kbnTestServer: {
...xPackAPITestsConfig.get('kbnTestServer'),
serverArgs: [
Expand Down
Loading