Skip to content

Commit a97249b

Browse files
committed
Merge branch 'main' into lucene_snapshot
2 parents 9fce7e7 + b40a520 commit a97249b

File tree

375 files changed

+10597
-5430
lines changed

Some content is hidden

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

375 files changed

+10597
-5430
lines changed

benchmarks/src/main/java/org/elasticsearch/benchmark/search/fetch/subphase/FetchSourcePhaseBenchmark.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public void setup() throws IOException {
6363
);
6464
includesSet = Set.of(fetchContext.includes());
6565
excludesSet = Set.of(fetchContext.excludes());
66-
parserConfig = XContentParserConfiguration.EMPTY.withFiltering(includesSet, excludesSet, false);
66+
parserConfig = XContentParserConfiguration.EMPTY.withFiltering(null, includesSet, excludesSet, false);
6767
}
6868

6969
private BytesReference read300BytesExample() throws IOException {

benchmarks/src/main/java/org/elasticsearch/benchmark/xcontent/FilterContentBenchmark.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ private XContentParserConfiguration buildParseConfig(boolean matchDotsInFieldNam
170170
includes = null;
171171
excludes = filters;
172172
}
173-
return XContentParserConfiguration.EMPTY.withFiltering(includes, excludes, matchDotsInFieldNames);
173+
return XContentParserConfiguration.EMPTY.withFiltering(null, includes, excludes, matchDotsInFieldNames);
174174
}
175175

176176
private BytesReference filter(XContentParserConfiguration contentParserConfiguration) throws IOException {

build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/DockerBase.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
* This class models the different Docker base images that are used to build Docker distributions of Elasticsearch.
1414
*/
1515
public enum DockerBase {
16-
// "latest" here is intentional, since the image name specifies "8"
17-
DEFAULT("docker.elastic.co/ubi8/ubi-minimal:latest", "", "microdnf"),
16+
// "latest" here is intentional, since the image name specifies "9"
17+
DEFAULT("docker.elastic.co/ubi9/ubi-minimal:latest", "", "microdnf"),
1818

1919
// The Iron Bank base image is UBI (albeit hardened), but we are required to parameterize the Docker build
2020
IRON_BANK("${BASE_REGISTRY}/${BASE_IMAGE}:${BASE_TAG}", "-ironbank", "yum"),

build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/ElasticsearchTestBasePlugin.java

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
import org.elasticsearch.gradle.test.GradleTestPolicySetupPlugin;
2121
import org.elasticsearch.gradle.test.SystemPropertyCommandLineArgumentProvider;
2222
import org.gradle.api.Action;
23+
import org.gradle.api.JavaVersion;
2324
import org.gradle.api.Plugin;
2425
import org.gradle.api.Project;
2526
import org.gradle.api.Task;
@@ -112,7 +113,6 @@ public void execute(Task t) {
112113
test.jvmArgs(
113114
"-Xmx" + System.getProperty("tests.heap.size", "512m"),
114115
"-Xms" + System.getProperty("tests.heap.size", "512m"),
115-
"-Djava.security.manager=allow",
116116
"-Dtests.testfeatures.enabled=true",
117117
"--add-opens=java.base/java.util=ALL-UNNAMED",
118118
// TODO: only open these for mockito when it is modularized
@@ -127,6 +127,13 @@ public void execute(Task t) {
127127
);
128128

129129
test.getJvmArgumentProviders().add(new SimpleCommandLineArgumentProvider("-XX:HeapDumpPath=" + heapdumpDir));
130+
test.getJvmArgumentProviders().add(() -> {
131+
if (test.getJavaVersion().compareTo(JavaVersion.VERSION_23) <= 0) {
132+
return List.of("-Djava.security.manager=allow");
133+
} else {
134+
return List.of();
135+
}
136+
});
130137

131138
String argline = System.getProperty("tests.jvm.argline");
132139
if (argline != null) {

build-tools/src/main/java/org/elasticsearch/gradle/test/GradleTestPolicySetupPlugin.java

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,14 @@
99

1010
package org.elasticsearch.gradle.test;
1111

12+
import org.gradle.api.JavaVersion;
1213
import org.gradle.api.Plugin;
1314
import org.gradle.api.Project;
1415
import org.gradle.api.invocation.Gradle;
1516
import org.gradle.api.tasks.testing.Test;
1617

18+
import java.util.List;
19+
1720
public class GradleTestPolicySetupPlugin implements Plugin<Project> {
1821

1922
@Override
@@ -23,8 +26,13 @@ public void apply(Project project) {
2326
test.systemProperty("tests.gradle", true);
2427
test.systemProperty("tests.task", test.getPath());
2528

26-
// Flag is required for later Java versions since our tests use a custom security manager
27-
test.jvmArgs("-Djava.security.manager=allow");
29+
test.getJvmArgumentProviders().add(() -> {
30+
if (test.getJavaVersion().compareTo(JavaVersion.VERSION_23) <= 0) {
31+
return List.of("-Djava.security.manager=allow");
32+
} else {
33+
return List.of();
34+
}
35+
});
2836

2937
SystemPropertyCommandLineArgumentProvider nonInputProperties = new SystemPropertyCommandLineArgumentProvider();
3038
// don't track these as inputs since they contain absolute paths and break cache relocatability

distribution/build.gradle

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,10 +70,10 @@ tasks.register("generateDependenciesReport", ConcatFilesTask) {
7070
// Explicitly add the dependency on the RHEL UBI Docker base image
7171
String[] rhelUbiFields = [
7272
'Red Hat Universal Base Image minimal',
73-
'8',
74-
'https://catalog.redhat.com/software/containers/ubi8/ubi-minimal/5c359a62bed8bd75a2c3fba8',
73+
'9',
74+
'https://catalog.redhat.com/software/containers/ubi9-minimal/61832888c0d15aff4912fe0d',
7575
'Custom;https://www.redhat.com/licenses/EULA_Red_Hat_Universal_Base_Image_English_20190422.pdf',
76-
'https://oss-dependencies.elastic.co/red-hat-universal-base-image-minimal/8/ubi-minimal-8-source.tar.gz'
76+
'https://oss-dependencies.elastic.co/red-hat-universal-base-image-minimal/9/ubi-minimal-9-source.tar.gz'
7777
]
7878
additionalLines << rhelUbiFields.join(',')
7979
}

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

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@
1111

1212
import org.elasticsearch.common.settings.Settings;
1313
import org.elasticsearch.common.util.concurrent.EsExecutors;
14+
import org.elasticsearch.core.UpdateForV9;
15+
import org.elasticsearch.jdk.RuntimeVersionFeature;
1416

1517
import java.io.IOException;
1618
import java.nio.file.Files;
@@ -137,9 +139,13 @@ private static Stream<String> maybeWorkaroundG1Bug() {
137139
return Stream.of();
138140
}
139141

142+
@UpdateForV9(owner = UpdateForV9.Owner.CORE_INFRA)
140143
private static Stream<String> maybeAllowSecurityManager() {
141-
// Will become conditional on useEntitlements once entitlements can run without SM
142-
return Stream.of("-Djava.security.manager=allow");
144+
if (RuntimeVersionFeature.isSecurityManagerAvailable()) {
145+
// Will become conditional on useEntitlements once entitlements can run without SM
146+
return Stream.of("-Djava.security.manager=allow");
147+
}
148+
return Stream.of();
143149
}
144150

145151
private static Stream<String> maybeAttachEntitlementAgent(boolean useEntitlements) {

docs/changelog/113827.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
pr: 113827
2+
summary: Add Optional Source Filtering to Source Loaders
3+
area: Mapping
4+
type: enhancement
5+
issues: []

docs/changelog/114618.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
pr: 114618
2+
summary: Add a new index setting to skip recovery source when synthetic source is enabled
3+
area: Logs
4+
type: enhancement
5+
issues: []

docs/changelog/116663.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
pr: 116663
2+
summary: KNN vector rescoring for quantized vectors
3+
area: Vector Search
4+
type: feature
5+
issues: []

0 commit comments

Comments
 (0)