Skip to content

Commit e469df8

Browse files
committed
Merge branch 'main' into to-aggregate-metric-double-function
2 parents 9e4f3b4 + 50e6894 commit e469df8

File tree

122 files changed

+3747
-947
lines changed

Some content is hidden

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

122 files changed

+3747
-947
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
*/
3030
public abstract class ArchivedOracleJdkToolchainResolver extends AbstractCustomJavaToolchainResolver {
3131

32-
private static final Map<Integer, String> ARCHIVED_BASE_VERSIONS = Maps.of(20, "20.0.2", 19, "19.0.2", 18, "18.0.2.1");
32+
private static final Map<Integer, String> ARCHIVED_BASE_VERSIONS = Maps.of(21, "21.0.6", 20, "20.0.2", 19, "19.0.2", 18, "18.0.2.1");
3333

3434
@Override
3535
public Optional<JavaToolchainDownload> resolve(JavaToolchainRequest request) {

build-tools/src/main/java/org/elasticsearch/gradle/testclusters/RunTask.java

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public abstract class RunTask extends DefaultTestClustersTask {
4242

4343
private Boolean debug = false;
4444
private Boolean cliDebug = false;
45-
private Boolean entitlementsEnabled = false;
45+
4646
private Boolean apmServerEnabled = false;
4747

4848
private Boolean preserveData = false;
@@ -74,9 +74,7 @@ public void setCliDebug(boolean enabled) {
7474
option = "entitlements",
7575
description = "Use the Entitlements agent system in place of SecurityManager to enforce sandbox policies."
7676
)
77-
public void setEntitlementsEnabled(boolean enabled) {
78-
this.entitlementsEnabled = enabled;
79-
}
77+
public void setEntitlementsEnabled(boolean enabled) {}
8078

8179
@Input
8280
public Boolean getDebug() {
@@ -90,7 +88,7 @@ public Boolean getCliDebug() {
9088

9189
@Input
9290
public Boolean getEntitlementsEnabled() {
93-
return entitlementsEnabled;
91+
return true;
9492
}
9593

9694
@Input
@@ -240,9 +238,7 @@ else if (node.getSettingKeys().contains("telemetry.metrics.enabled") == false) {
240238
if (cliDebug) {
241239
enableCliDebug();
242240
}
243-
if (entitlementsEnabled) {
244-
enableEntitlements();
245-
}
241+
enableEntitlements();
246242
}
247243

248244
@TaskAction

build.gradle

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -404,6 +404,34 @@ allprojects {
404404
apply plugin: 'elasticsearch.formatting'
405405
}
406406

407+
tasks.named("updateDaemonJvm") {
408+
def myPlatforms = [
409+
BuildPlatformFactory.of(
410+
org.gradle.platform.Architecture.AARCH64,
411+
org.gradle.platform.OperatingSystem.MAC_OS
412+
),
413+
BuildPlatformFactory.of(
414+
org.gradle.platform.Architecture.AARCH64,
415+
org.gradle.platform.OperatingSystem.LINUX
416+
),
417+
BuildPlatformFactory.of(
418+
org.gradle.platform.Architecture.X86_64,
419+
org.gradle.platform.OperatingSystem.LINUX
420+
),
421+
BuildPlatformFactory.of(
422+
org.gradle.platform.Architecture.X86_64,
423+
org.gradle.platform.OperatingSystem.WINDOWS
424+
),
425+
// anyone still using x86 osx?
426+
BuildPlatformFactory.of(
427+
org.gradle.platform.Architecture.X86_64,
428+
org.gradle.platform.OperatingSystem.MAC_OS
429+
)
430+
]
431+
toolchainPlatforms.set(myPlatforms)
432+
languageVersion = JavaLanguageVersion.of(21)
433+
vendor = JvmVendorSpec.ADOPTIUM
434+
}
407435

408436
tasks.register("verifyBwcTestsEnabled") {
409437
doLast {

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

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

1212
import org.elasticsearch.common.settings.Settings;
1313
import org.elasticsearch.common.util.concurrent.EsExecutors;
14-
import org.elasticsearch.core.Booleans;
1514
import org.elasticsearch.jdk.RuntimeVersionFeature;
1615

1716
import java.io.IOException;
@@ -28,9 +27,8 @@ static List<String> systemJvmOptions(Settings nodeSettings, final Map<String, St
2827
String distroType = sysprops.get("es.distribution.type");
2928
String javaType = sysprops.get("es.java.type");
3029
boolean isHotspot = sysprops.getOrDefault("sun.management.compiler", "").contains("HotSpot");
31-
boolean entitlementsExplicitlyEnabled = Booleans.parseBoolean(sysprops.getOrDefault("es.entitlements.enabled", "true"));
32-
// java 24+ only supports entitlements, but it may be enabled on earlier versions explicitly
33-
boolean useEntitlements = RuntimeVersionFeature.isSecurityManagerAvailable() == false || entitlementsExplicitlyEnabled;
30+
31+
boolean useEntitlements = true;
3432
return Stream.of(
3533
Stream.of(
3634
/*

distribution/tools/server-cli/src/test/java/org/elasticsearch/server/cli/ServerCliTests.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ public void testElasticsearchSettingCanNotBeEmpty() throws Exception {
185185
}
186186

187187
public void testElasticsearchSettingCanNotBeDuplicated() throws Exception {
188-
assertUsage(containsString("setting [foo] already set, saw [bar] and [baz]"), "-E", "foo=bar", "-E", "foo=baz");
188+
assertUsage(containsString("setting [foo] set twice via command line -E"), "-E", "foo=bar", "-E", "foo=baz");
189189
}
190190

191191
public void testUnknownOption() throws Exception {

docs/changelog/120869.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
pr: 120869
2+
summary: Threadpool merge scheduler
3+
area: Engine
4+
type: feature
5+
issues: []

docs/changelog/125054.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
pr: 125054
2+
summary: Truncate `step_info` and error reason in ILM execution state and history
3+
area: ILM+SLM
4+
type: enhancement
5+
issues:
6+
- 124181

docs/changelog/125117.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
pr: 125117
2+
summary: "Permanently switch from Java SecurityManager to Entitlements.
3+
The Java SecurityManager has been deprecated since Java 17, and it is now completely disabled in Java 24. In order
4+
to retain an similar level of protection, Elasticsearch implemented its own protection mechanism, Entitlements.
5+
Starting with this version, Entitlements will permanently replace the Java SecurityManager."
6+
area: Infra/Core
7+
type: upgrade
8+
issues: []

docs/reference/elasticsearch/configuration-reference/auding-settings.md

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
navigation_title: "Auditing settings"
33
mapped_pages:
44
- https://www.elastic.co/guide/en/elasticsearch/reference/current/auditing-settings.html
5+
applies_to:
6+
deployment:
7+
ess:
8+
self:
59
---
610

711
# Auditing security settings [auditing-settings]
@@ -20,7 +24,7 @@ If configured, auditing settings must be set on every node in the cluster. Stati
2024

2125
$$$xpack-security-audit-enabled$$$
2226

23-
`xpack.security.audit.enabled`
27+
`xpack.security.audit.enabled` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
2428
: ([Static](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#static-cluster-setting)) Set to `true` to enable auditing on the node. The default value is `false`. This puts the auditing events in a dedicated file named `<clustername>_audit.json` on each node.
2529

2630
If enabled, this setting must be configured in `elasticsearch.yml` on all nodes in the cluster.
@@ -33,17 +37,17 @@ The events and some other information about what gets logged can be controlled b
3337

3438
$$$xpack-sa-lf-events-include$$$
3539

36-
`xpack.security.audit.logfile.events.include`
40+
`xpack.security.audit.logfile.events.include` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
3741
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) Specifies the [kind of events](/reference/elasticsearch/elasticsearch-audit-events.md) to print in the auditing output. In addition, `_all` can be used to exhaustively audit all the events, but this is usually discouraged since it will get very verbose. The default list value contains: `access_denied, access_granted, anonymous_access_denied, authentication_failed, connection_denied, tampered_request, run_as_denied, run_as_granted, security_config_change`.
3842

3943
$$$xpack-sa-lf-events-exclude$$$
4044

41-
`xpack.security.audit.logfile.events.exclude`
45+
`xpack.security.audit.logfile.events.exclude` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
4246
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) Excludes the specified [kind of events](/reference/elasticsearch/elasticsearch-audit-events.md) from the include list. This is useful in the case where the `events.include` setting contains the special value `_all`. The default is the empty list.
4347

4448
$$$xpack-sa-lf-events-emit-request$$$
4549

46-
`xpack.security.audit.logfile.events.emit_request_body`
50+
`xpack.security.audit.logfile.events.emit_request_body` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
4751
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) Specifies whether to include the full request body from REST requests as an attribute of certain kinds of audit events. This setting can be used to [audit search queries](docs-content://deploy-manage/monitor/logging-configuration/auditing-search-queries.md).
4852

4953
The default value is `false`, so request bodies are not printed.
@@ -58,22 +62,22 @@ $$$xpack-sa-lf-events-emit-request$$$
5862

5963
$$$xpack-sa-lf-emit-node-name$$$
6064

61-
`xpack.security.audit.logfile.emit_node_name`
65+
`xpack.security.audit.logfile.emit_node_name` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
6266
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) Specifies whether to include the [node name](docs-content://deploy-manage/deploy/self-managed/important-settings-configuration.md#node-name) as a field in each audit event. The default value is `false`.
6367

6468
$$$xpack-sa-lf-emit-node-host-address$$$
6569

66-
`xpack.security.audit.logfile.emit_node_host_address`
70+
`xpack.security.audit.logfile.emit_node_host_address` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
6771
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) Specifies whether to include the node’s IP address as a field in each audit event. The default value is `false`.
6872

6973
$$$xpack-sa-lf-emit-node-host-name$$$
7074

71-
`xpack.security.audit.logfile.emit_node_host_name`
75+
`xpack.security.audit.logfile.emit_node_host_name` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
7276
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) Specifies whether to include the node’s host name as a field in each audit event. The default value is `false`.
7377

7478
$$$xpack-sa-lf-emit-node-id$$$
7579

76-
`xpack.security.audit.logfile.emit_node_id`
80+
`xpack.security.audit.logfile.emit_node_id` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
7781
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) Specifies whether to include the node id as a field in each audit event. Unlike [node name](docs-content://deploy-manage/deploy/self-managed/important-settings-configuration.md#node-name), whose value might change if the administrator changes the setting in the config file, the node id will persist across cluster restarts and the administrator cannot change it. The default value is `true`.
7882

7983

@@ -83,27 +87,27 @@ The following settings affect the [ignore policies](docs-content://deploy-manage
8387

8488
$$$xpack-sa-lf-events-ignore-users$$$
8589

86-
`xpack.security.audit.logfile.events.ignore_filters.<policy_name>.users`
90+
`xpack.security.audit.logfile.events.ignore_filters.<policy_name>.users` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
8791
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) A list of user names or wildcards. The specified policy will not print audit events for users matching these values.
8892

8993
$$$xpack-sa-lf-events-ignore-realms$$$
9094

91-
`xpack.security.audit.logfile.events.ignore_filters.<policy_name>.realms`
95+
`xpack.security.audit.logfile.events.ignore_filters.<policy_name>.realms` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
9296
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) A list of authentication realm names or wildcards. The specified policy will not print audit events for users in these realms.
9397

9498
$$$xpack-sa-lf-events-ignore-actions$$$
9599

96-
`xpack.security.audit.logfile.events.ignore_filters.<policy_name>.actions`
100+
`xpack.security.audit.logfile.events.ignore_filters.<policy_name>.actions` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
97101
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) A list of action names or wildcards. Action name can be found in the `action` field of the audit event. The specified policy will not print audit events for actions matching these values.
98102

99103
$$$xpack-sa-lf-events-ignore-roles$$$
100104

101-
`xpack.security.audit.logfile.events.ignore_filters.<policy_name>.roles`
105+
`xpack.security.audit.logfile.events.ignore_filters.<policy_name>.roles` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
102106
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) A list of role names or wildcards. The specified policy will not print audit events for users that have these roles. If the user has several roles, some of which are **not** covered by the policy, the policy will **not** cover this event.
103107

104108
$$$xpack-sa-lf-events-ignore-indices$$$
105109

106-
`xpack.security.audit.logfile.events.ignore_filters.<policy_name>.indices`
110+
`xpack.security.audit.logfile.events.ignore_filters.<policy_name>.indices` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
107111
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) A list of index names or wildcards. The specified policy will not print audit events when all the indices in the event match these values. If the event concerns several indices, some of which are **not** covered by the policy, the policy will **not** cover this event.
108112

109113

docs/reference/elasticsearch/configuration-reference/circuit-breaker-settings.md

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
---
22
mapped_pages:
33
- https://www.elastic.co/guide/en/elasticsearch/reference/current/circuit-breaker.html
4+
applies_to:
5+
deployment:
6+
ess:
7+
self:
48
---
59

610
# Circuit breaker settings [circuit-breaker]
@@ -26,7 +30,7 @@ The parent-level breaker can be configured with the following settings:
2630

2731
$$$indices-breaker-total-limit$$$
2832

29-
`indices.breaker.total.limit` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on {{ess}}")
33+
`indices.breaker.total.limit` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
3034
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) Starting limit for overall parent breaker. Defaults to 70% of JVM heap if `indices.breaker.total.use_real_memory` is `false`. If `indices.breaker.total.use_real_memory` is `true`, defaults to 95% of the JVM heap.
3135

3236

@@ -36,12 +40,12 @@ The field data circuit breaker estimates the heap memory required to load a fiel
3640

3741
$$$fielddata-circuit-breaker-limit$$$
3842

39-
`indices.breaker.fielddata.limit` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on {{ess}}")
43+
`indices.breaker.fielddata.limit` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
4044
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) Limit for fielddata breaker. Defaults to 40% of JVM heap.
4145

4246
$$$fielddata-circuit-breaker-overhead$$$
4347

44-
`indices.breaker.fielddata.overhead` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on {{ess}}")
48+
`indices.breaker.fielddata.overhead` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
4549
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) A constant that all field data estimations are multiplied with to determine a final estimation. Defaults to `1.03`.
4650

4751

@@ -51,12 +55,12 @@ The request circuit breaker allows Elasticsearch to prevent per-request data str
5155

5256
$$$request-breaker-limit$$$
5357

54-
`indices.breaker.request.limit` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on {{ess}}")
58+
`indices.breaker.request.limit` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
5559
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) Limit for request breaker, defaults to 60% of JVM heap.
5660

5761
$$$request-breaker-overhead$$$
5862

59-
`indices.breaker.request.overhead` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on {{ess}}")
63+
`indices.breaker.request.overhead` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
6064
: ([Dynamic](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#dynamic-cluster-setting)) A constant that all request estimations are multiplied with to determine a final estimation. Defaults to `1`.
6165

6266

@@ -89,7 +93,7 @@ Poorly written regular expressions can degrade cluster stability and performance
8993

9094
$$$script-painless-regex-enabled$$$
9195

92-
`script.painless.regex.enabled`
96+
`script.painless.regex.enabled` ![logo cloud](https://doc-icons.s3.us-east-2.amazonaws.com/logo_cloud.svg "Supported on Elastic Cloud Hosted")
9397
: ([Static](docs-content://deploy-manage/deploy/self-managed/configure-elasticsearch.md#static-cluster-setting)) Enables regex in Painless scripts. Accepts:
9498

9599
`limited` (Default)

0 commit comments

Comments
 (0)