|
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;
|
|
118 | 121 | * And assert that the result exists and is equal to "value".
|
119 | 122 | */
|
120 | 123 | @ClusterScope(scope = SUITE, numClientNodes = 1, numDataNodes = 1)
|
| 124 | +@LuceneTestCase.SuppressFileSystems(value = "HandleLimitFS") |
121 | 125 | public class LookupJoinTypesIT extends ESIntegTestCase {
|
122 | 126 | protected Collection<Class<? extends Plugin>> nodePlugins() {
|
123 | 127 | return List.of(
|
@@ -363,16 +367,18 @@ private void initIndexes(String group) {
|
363 | 367 | private void initData(String group) {
|
364 | 368 | Collection<TestConfig> configs = testConfigurations.get(group).configs.values();
|
365 | 369 | int docId = 0;
|
| 370 | + List<IndexRequestBuilder> indexRequests = new ArrayList<>(configs.size()); |
366 | 371 | for (TestConfig config : configs) {
|
367 | 372 | String doc = String.format(Locale.ROOT, """
|
368 | 373 | {
|
369 | 374 | %s,
|
370 | 375 | "other": "value"
|
371 | 376 | }
|
372 | 377 | """, lookupPropertyFor(config));
|
373 |
| - index(config.indexName(), "" + (++docId), doc); |
374 |
| - refresh(config.indexName()); |
| 378 | + var indexRequest = client().prepareIndex().setIndex(config.indexName()).setId("" + (++docId)).setSource(doc, XContentType.JSON); |
| 379 | + indexRequests.add(indexRequest); |
375 | 380 | }
|
| 381 | + indexRandom(true, indexRequests); |
376 | 382 | List<String> mainProperties = configs.stream().map(this::mainPropertyFor).distinct().collect(Collectors.toList());
|
377 | 383 | index("index", "1", String.format(Locale.ROOT, """
|
378 | 384 | {
|
|
0 commit comments