Skip to content

Commit 07a3629

Browse files
committed
Merge remote-tracking branch 'origin/main' into mapper/analyzer-params
2 parents 4e3c548 + 131da70 commit 07a3629

File tree

380 files changed

+8675
-3496
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

380 files changed

+8675
-3496
lines changed
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
---
2+
- job:
3+
name: elastic+elasticsearch+%BRANCH%+dra-staging-update
4+
display-name: "elastic / elasticsearch # %BRANCH% - DRA staging update"
5+
description: "Scheduled job to check for staging dependency updates"
6+
node: master
7+
scm: []
8+
properties: []
9+
parameters: []
10+
publishers: []
11+
triggers:
12+
- timed: "*/30 * * * *"
13+
builders:
14+
- conditional-step:
15+
condition-kind: shell
16+
condition-command: |
17+
#!/usr/bin/env bash
18+
set -e
19+
# Don't publish main branch to staging
20+
if [ "%BRANCH%" == "main" ]; then
21+
exit 1
22+
fi
23+
24+
RM_BRANCH="%BRANCH%" && [[ "%BRANCH%" == "main" ]] && RM_BRANCH=master
25+
BEATS_MANIFEST=$(curl -sS https://artifacts-staging.elastic.co/beats/latest/${RM_BRANCH}.json | jq -r '.manifest_url')
26+
ML_MANIFEST=$(curl -sS https://artifacts-staging.elastic.co/ml-cpp/latest/${RM_BRANCH}.json | jq -r '.manifest_url')
27+
ES_MANIFEST=$(curl -sS https://artifacts-staging.elastic.co/elasticsearch/latest/${RM_BRANCH}.json | jq -r '.manifest_url')
28+
ES_BEATS_DEPENDENCY=$(curl -sS $ES_MANIFEST | jq -r '.projects.elasticsearch.dependencies[] | select(.prefix == "beats") | .build_uri')
29+
ES_ML_DEPENDENCY=$(curl -sS $ES_MANIFEST | jq -r '.projects.elasticsearch.dependencies[] | select(.prefix == "ml-cpp") | .build_uri')
30+
31+
if [ "$BEATS_MANIFEST" = "$ES_BEATS_DEPENDENCY" ]; then
32+
echo "ES has the latest beats"
33+
else
34+
echo "Need to trigger a build, $BEATS_MANIFEST available but ES has $ES_BEATS_DEPENDENCY"
35+
exit 0
36+
fi
37+
38+
if [ "$ML_MANIFEST" = "$ES_ML_DEPENDENCY" ]; then
39+
echo "ES has the latest ml-cpp"
40+
else
41+
echo "Need to trigger a build, $ML_MANIFEST available but ES has $ES_ML_DEPENDENCY"
42+
exit 0
43+
fi
44+
45+
# A non-zero exit value means the trigger step will be skipped
46+
exit 1
47+
steps:
48+
- trigger-builds:
49+
- project: "elastic+elasticsearch+%BRANCH%+triggers/elastic+elasticsearch+%BRANCH%+dra-staging-trigger"
50+
current-parameters: false
51+
git-revision: false

.ci/packer_cache.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ else
3636
rm -rf checkout/6.8
3737
git clone --reference $(dirname "${SCRIPT}")/../.git https://github.com/elastic/elasticsearch.git --branch 6.8 --single-branch checkout/6.8
3838
export JAVA_HOME="${JAVA11_HOME}"
39-
./checkout/6.8/gradlew --project-dir ./checkout/6.8 --parallel clean --scan -Porg.elasticsearch.acceptScanTOS=true --stacktrace resolveAllDependencies
39+
./checkout/6.8/gradlew --project-dir ./checkout/6.8 --parallel clean --stacktrace resolveAllDependencies
4040
rm -rf ./checkout/6.8
4141
fi
4242

CONTRIBUTING.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,9 +69,8 @@ cycle.
6969
* Lines that are not part of your change should not be edited (e.g. don't format
7070
unchanged lines, don't reorder existing imports)
7171
* Add the appropriate [license headers](#license-headers) to any new files
72-
* For contributions involving the elasticsearch build you can find (details about the build setup in the
73-
[BUILDING](BUILDING.md) file)
74-
72+
* For contributions involving the elasticsearch build you can find details about the build setup in the
73+
[BUILDING](BUILDING.md) file
7574

7675
### Submitting your changes
7776

benchmarks/src/main/java/org/elasticsearch/benchmark/index/mapper/MapperServiceFactory.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,9 @@ public static MapperService create(String mappings) {
5252
SimilarityService similarityService = new SimilarityService(indexSettings, null, Map.of());
5353
MapperService mapperService = new MapperService(
5454
indexSettings,
55-
new IndexAnalyzers(
55+
IndexAnalyzers.of(
5656
Map.of("default", new NamedAnalyzer("default", AnalyzerScope.INDEX, new StandardAnalyzer())),
57-
Map.of("lowercase", new NamedAnalyzer("lowercase", AnalyzerScope.INDEX, new LowercaseNormalizer())),
58-
Map.of()
57+
Map.of("lowercase", new NamedAnalyzer("lowercase", AnalyzerScope.INDEX, new LowercaseNormalizer()))
5958
),
6059
XContentParserConfiguration.EMPTY.withRegistry(new NamedXContentRegistry(ClusterModule.getNamedXWriteables()))
6160
.withDeprecationHandler(LoggingDeprecationHandler.INSTANCE),

benchmarks/src/main/java/org/elasticsearch/benchmark/script/ScriptScoreBenchmark.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,6 @@
5858
import java.nio.file.Path;
5959
import java.util.List;
6060
import java.util.Map;
61-
import java.util.Set;
6261
import java.util.concurrent.TimeUnit;
6362

6463
/**
@@ -85,7 +84,6 @@ public class ScriptScoreBenchmark {
8584
Map.entry("n", new NumberFieldType("n", NumberType.LONG, false, false, true, true, null, Map.of(), null, false, null, null))
8685
);
8786
private final IndexFieldDataCache fieldDataCache = new IndexFieldDataCache.None();
88-
private final Map<String, Set<String>> sourcePaths = Map.of("n", Set.of("n"));
8987
private final CircuitBreakerService breakerService = new NoneCircuitBreakerService();
9088
private final SearchLookup lookup = new SearchLookup(
9189
fieldTypes::get,

benchmarks/src/main/java/org/elasticsearch/benchmark/search/QueryParserHelperBenchmark.java

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
package org.elasticsearch.benchmark.search;
1010

1111
import org.apache.logging.log4j.util.Strings;
12-
import org.apache.lucene.analysis.standard.StandardAnalyzer;
1312
import org.apache.lucene.index.DirectoryReader;
1413
import org.apache.lucene.index.IndexReader;
1514
import org.apache.lucene.index.IndexWriter;
@@ -23,13 +22,11 @@
2322
import org.elasticsearch.common.bytes.BytesArray;
2423
import org.elasticsearch.common.compress.CompressedXContent;
2524
import org.elasticsearch.common.io.stream.NamedWriteableRegistry;
25+
import org.elasticsearch.common.lucene.Lucene;
2626
import org.elasticsearch.common.settings.Settings;
2727
import org.elasticsearch.common.xcontent.LoggingDeprecationHandler;
2828
import org.elasticsearch.core.IOUtils;
2929
import org.elasticsearch.index.IndexSettings;
30-
import org.elasticsearch.index.analysis.AnalyzerScope;
31-
import org.elasticsearch.index.analysis.IndexAnalyzers;
32-
import org.elasticsearch.index.analysis.NamedAnalyzer;
3330
import org.elasticsearch.index.fielddata.IndexFieldDataCache;
3431
import org.elasticsearch.index.mapper.MapperRegistry;
3532
import org.elasticsearch.index.mapper.MapperService;
@@ -173,11 +170,7 @@ protected final MapperService createMapperService(String mappings) {
173170
SimilarityService similarityService = new SimilarityService(indexSettings, null, Map.of());
174171
MapperService mapperService = new MapperService(
175172
indexSettings,
176-
new IndexAnalyzers(
177-
Map.of("default", new NamedAnalyzer("default", AnalyzerScope.INDEX, new StandardAnalyzer())),
178-
Map.of(),
179-
Map.of()
180-
),
173+
(type, name) -> Lucene.STANDARD_ANALYZER,
181174
XContentParserConfiguration.EMPTY.withRegistry(new NamedXContentRegistry(ClusterModule.getNamedXWriteables()))
182175
.withDeprecationHandler(LoggingDeprecationHandler.INSTANCE),
183176
similarityService,

distribution/tools/server-cli/src/main/java/org/elasticsearch/server/cli/SystemJvmOptions.java

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,10 +58,8 @@ static List<String> systemJvmOptions() {
5858
/*
5959
* Temporarily suppress illegal reflective access in searchable snapshots shared cache preallocation; this is temporary while we
6060
* explore alternatives. See org.elasticsearch.xpack.searchablesnapshots.preallocate.Preallocate.
61-
*
62-
* TODO: either modularlize Elasticsearch so that we can limit the opening of this module, or find an alternative
6361
*/
64-
"--add-opens=java.base/java.io=ALL-UNNAMED",
62+
"--add-opens=java.base/java.io=org.elasticsearch.blobcache.preallocate",
6563
maybeOverrideDockerCgroup()
6664
).stream().filter(e -> e.isEmpty() == false).collect(Collectors.toList());
6765
}

docs/changelog/93524.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
pr: 93524
2+
summary: Reduce the likelihood of writing small segments due to an oversize translog
3+
area: Engine
4+
type: enhancement
5+
issues:
6+
- 75611

docs/changelog/94543.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
pr: 94543
2+
summary: Report transport message size per action
3+
area: Network
4+
type: enhancement
5+
issues:
6+
- 88151

docs/changelog/94702.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
pr: 94702
2+
summary: Fix async enrich execution prematurely releases enrich policy lock
3+
area: Ingest Node
4+
type: bug
5+
issues:
6+
- 94690

0 commit comments

Comments
 (0)