|
7 | 7 |
|
8 | 8 | package org.elasticsearch.xpack.esql.action; |
9 | 9 |
|
| 10 | +import org.apache.lucene.tests.util.LuceneTestCase; |
| 11 | +import org.elasticsearch.action.index.IndexRequestBuilder; |
10 | 12 | import org.elasticsearch.common.settings.Settings; |
11 | 13 | import org.elasticsearch.index.mapper.extras.MapperExtrasPlugin; |
12 | 14 | import org.elasticsearch.plugins.Plugin; |
13 | 15 | import org.elasticsearch.test.ESIntegTestCase; |
14 | 16 | import org.elasticsearch.test.ESIntegTestCase.ClusterScope; |
| 17 | +import org.elasticsearch.xcontent.XContentType; |
15 | 18 | import org.elasticsearch.xpack.core.esql.action.ColumnInfo; |
16 | 19 | import org.elasticsearch.xpack.esql.VerificationException; |
17 | 20 | import org.elasticsearch.xpack.esql.core.type.DataType; |
|
117 | 120 | * And assert that the result exists and is equal to "value". |
118 | 121 | */ |
119 | 122 | @ClusterScope(scope = SUITE, numClientNodes = 1, numDataNodes = 1) |
| 123 | +@LuceneTestCase.SuppressFileSystems(value = "HandleLimitFS") |
120 | 124 | public class LookupJoinTypesIT extends ESIntegTestCase { |
121 | 125 | protected Collection<Class<? extends Plugin>> nodePlugins() { |
122 | 126 | return List.of( |
@@ -357,16 +361,18 @@ private void initIndexes(String group) { |
357 | 361 | private void initData(String group) { |
358 | 362 | Collection<TestConfig> configs = testConfigurations.get(group).configs.values(); |
359 | 363 | int docId = 0; |
| 364 | + List<IndexRequestBuilder> indexRequests = new ArrayList<>(configs.size()); |
360 | 365 | for (TestConfig config : configs) { |
361 | 366 | String doc = String.format(Locale.ROOT, """ |
362 | 367 | { |
363 | 368 | %s, |
364 | 369 | "other": "value" |
365 | 370 | } |
366 | 371 | """, lookupPropertyFor(config)); |
367 | | - index(config.indexName(), "" + (++docId), doc); |
368 | | - refresh(config.indexName()); |
| 372 | + var indexRequest = client().prepareIndex().setIndex(config.indexName()).setId("" + (++docId)).setSource(doc, XContentType.JSON); |
| 373 | + indexRequests.add(indexRequest); |
369 | 374 | } |
| 375 | + indexRandom(true, indexRequests); |
370 | 376 | List<String> mainProperties = configs.stream().map(this::mainPropertyFor).distinct().collect(Collectors.toList()); |
371 | 377 | index("index", "1", String.format(Locale.ROOT, """ |
372 | 378 | { |
|
0 commit comments