Skip to content

Commit 883f631

Browse files
authored
Disable ILM history store in data stream module YAML test suite (elastic#132313)
The creation of the ILM history store can disturb tests that expect a fixed number of data streams to be present. None of the tests in this YAML test suite interact with the ILM history store, so we can safely disable it. Fixes elastic#132298
1 parent 58c5044 commit 883f631

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

modules/data-streams/src/yamlRestTest/java/org/elasticsearch/datastreams/DataStreamsClientYamlTestSuiteIT.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,12 @@ private static ElasticsearchCluster createCluster() {
5858
if (setNodes) {
5959
clusterBuilder.nodes(2);
6060
}
61+
// We need to disable ILM history based on a setting, to avoid errors in Serverless where the setting is not available.
62+
boolean disableILMHistory = Booleans.parseBoolean(System.getProperty("yaml.rest.tests.disable_ilm_history", "true"));
63+
if (disableILMHistory) {
64+
// disable ILM history, since it disturbs tests
65+
clusterBuilder.setting("indices.lifecycle.history_index_enabled", "false");
66+
}
6167
return clusterBuilder.build();
6268
}
6369

muted-tests.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -476,9 +476,6 @@ tests:
476476
- class: org.elasticsearch.common.logging.JULBridgeTests
477477
method: testThrowable
478478
issue: https://github.com/elastic/elasticsearch/issues/132280
479-
- class: org.elasticsearch.datastreams.DataStreamsClientYamlTestSuiteIT
480-
method: test {p0=data_stream/10_basic/Create hidden data stream with match all template}
481-
issue: https://github.com/elastic/elasticsearch/issues/132298
482479
- class: org.elasticsearch.xpack.ml.integration.AutodetectMemoryLimitIT
483480
method: testManyDistinctOverFields
484481
issue: https://github.com/elastic/elasticsearch/issues/132308

0 commit comments

Comments
 (0)