Skip to content

Commit c27b263

Browse files
committed
Merge branch 'upstream/master' into reuse-date-stream-timestamp
* upstream/master: (24 commits) Implement framework for migrating system indices (elastic#78951) Improve transient settings deprecation message (elastic#79504) Remove getValue and getValues from Field (elastic#79516) Store Template's mappings as bytes for disk serialization (elastic#78746) [ML] Add queue_capacity setting to start deployment API (elastic#79433) [ML] muting rest compat test issue elastic#79518 (elastic#79519) Avoid redundant available indices check (elastic#76540) Re-enable BWC tests TEST Ensure password 14 chars length on Kerberos FIPS tests (elastic#79496) [DOCS] Temporarily remove APM links (elastic#79411) Fix CCSDuelIT for skipped shards (elastic#79490) Add other time accounting in HotThreads (elastic#79392) Add deprecation info API entries for deprecated monitoring settings (elastic#78799) Add note in breaking changes for nameid_format (elastic#77785) Use 'migration' instead of 'upgrade' in GET system feature migration status responses (elastic#79302) Upgrade lucene version 8b68bf60c98 (elastic#79461) Use Strings#EMPTY_ARRAY (elastic#79452) Quicker shared cache file preallocation (elastic#79447) [ML] Removing some code that's obsolete for 8.0 (elastic#79444) Ensure indexing_data CCR requests are compressed (elastic#79413) ...
2 parents db25634 + 1a90689 commit c27b263

File tree

182 files changed

+4271
-930
lines changed

Some content is hidden

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

182 files changed

+4271
-930
lines changed

build-tools-internal/version.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
elasticsearch = 8.0.0
2-
lucene = 9.0.0-snapshot-cfd9f9f98f7
2+
lucene = 9.0.0-snapshot-8b68bf60c98
33

44
bundled_jdk_vendor = adoptium
55
bundled_jdk = 17+35

build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -132,9 +132,9 @@ tasks.register("verifyVersions") {
132132
* after the backport of the backcompat code is complete.
133133
*/
134134

135-
boolean bwc_tests_enabled = false
135+
boolean bwc_tests_enabled = true
136136
// place a PR link here when committing bwc changes:
137-
String bwc_tests_disabled_issue = "https://github.com/elastic/elasticsearch/pull/79385"
137+
String bwc_tests_disabled_issue = ""
138138
/*
139139
* FIPS 140-2 behavior was fixed in 7.11.0. Before that there is no way to run elasticsearch in a
140140
* JVM that is properly configured to be in fips mode with BCFIPS. For now we need to disable

client/rest-high-level/src/main/java/org/elasticsearch/client/migration/GetFeatureUpgradeStatusResponse.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
public class GetFeatureUpgradeStatusResponse {
2626

2727
private static final ParseField FEATURE_UPGRADE_STATUSES = new ParseField("features");
28-
private static final ParseField UPGRADE_STATUS = new ParseField("upgrade_status");
28+
private static final ParseField UPGRADE_STATUS = new ParseField("migration_status");
2929

3030
private final List<FeatureUpgradeStatus> featureUpgradeStatuses;
3131
private final String upgradeStatus;
@@ -76,7 +76,7 @@ public static class FeatureUpgradeStatus {
7676

7777
private static final ParseField FEATURE_NAME = new ParseField("feature_name");
7878
private static final ParseField MINIMUM_INDEX_VERSION = new ParseField("minimum_index_version");
79-
private static final ParseField UPGRADE_STATUS = new ParseField("upgrade_status");
79+
private static final ParseField UPGRADE_STATUS = new ParseField("migration_status");
8080
private static final ParseField INDEX_VERSIONS = new ParseField("indices");
8181

8282
@SuppressWarnings("unchecked")

client/rest-high-level/src/test/java/org/elasticsearch/client/MigrationIT.java

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@
2323

2424
import static org.hamcrest.Matchers.equalTo;
2525
import static org.hamcrest.Matchers.greaterThanOrEqualTo;
26+
import static org.hamcrest.Matchers.hasSize;
2627
import static org.hamcrest.Matchers.is;
27-
import static org.hamcrest.Matchers.nullValue;
2828

2929
public class MigrationIT extends ESRestHighLevelClientTestCase {
3030

@@ -42,7 +42,7 @@ public void testGetDeprecationInfo() throws IOException {
4242
public void testGetFeatureUpgradeStatus() throws IOException {
4343
GetFeatureUpgradeStatusRequest request = new GetFeatureUpgradeStatusRequest();
4444
GetFeatureUpgradeStatusResponse response = highLevelClient().migration().getFeatureUpgradeStatus(request, RequestOptions.DEFAULT);
45-
assertThat(response.getUpgradeStatus(), equalTo("NO_UPGRADE_NEEDED"));
45+
assertThat(response.getUpgradeStatus(), equalTo("NO_MIGRATION_NEEDED"));
4646
assertThat(response.getFeatureUpgradeStatuses().size(), greaterThanOrEqualTo(1));
4747
Optional<GetFeatureUpgradeStatusResponse.FeatureUpgradeStatus> optionalTasksStatus = response.getFeatureUpgradeStatuses().stream()
4848
.filter(status -> "tasks".equals(status.getFeatureName()))
@@ -52,19 +52,16 @@ public void testGetFeatureUpgradeStatus() throws IOException {
5252

5353
GetFeatureUpgradeStatusResponse.FeatureUpgradeStatus tasksStatus = optionalTasksStatus.get();
5454

55-
assertThat(tasksStatus.getUpgradeStatus(), equalTo("NO_UPGRADE_NEEDED"));
55+
assertThat(tasksStatus.getUpgradeStatus(), equalTo("NO_MIGRATION_NEEDED"));
5656
assertThat(tasksStatus.getMinimumIndexVersion(), equalTo(Version.CURRENT.toString()));
5757
assertThat(tasksStatus.getFeatureName(), equalTo("tasks"));
5858
}
5959

6060
public void testPostFeatureUpgradeStatus() throws IOException {
6161
PostFeatureUpgradeRequest request = new PostFeatureUpgradeRequest();
6262
PostFeatureUpgradeResponse response = highLevelClient().migration().postFeatureUpgrade(request, RequestOptions.DEFAULT);
63-
assertThat(response.isAccepted(), equalTo(true));
64-
assertThat(response.getFeatures().size(), equalTo(1));
65-
PostFeatureUpgradeResponse.Feature feature = response.getFeatures().get(0);
66-
assertThat(feature.getFeatureName(), equalTo("security"));
67-
assertThat(response.getReason(), nullValue());
68-
assertThat(response.getElasticsearchException(), nullValue());
63+
assertThat(response.isAccepted(), equalTo(false));
64+
assertThat(response.getFeatures(), hasSize(0));
65+
assertThat(response.getReason(), equalTo("No system indices require migration"));
6966
}
7067
}

client/rest-high-level/src/test/java/org/elasticsearch/client/indices/GetComponentTemplatesResponseTests.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
import org.elasticsearch.cluster.metadata.Template;
1414
import org.elasticsearch.common.compress.CompressedXContent;
1515
import org.elasticsearch.common.settings.Settings;
16+
import org.elasticsearch.xcontent.ToXContent;
1617
import org.elasticsearch.xcontent.XContentBuilder;
1718
import org.elasticsearch.test.ESTestCase;
1819

@@ -79,7 +80,7 @@ private static void toXContent(GetComponentTemplatesResponse response, XContentB
7980
builder.startObject();
8081
builder.field("name", e.getKey());
8182
builder.field("component_template");
82-
e.getValue().toXContent(builder, null);
83+
e.getValue().toXContent(builder, ToXContent.EMPTY_PARAMS);
8384
builder.endObject();
8485
}
8586
builder.endArray();

client/rest-high-level/src/test/java/org/elasticsearch/client/indices/GetComposableIndexTemplatesResponseTests.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010

1111
import org.elasticsearch.cluster.metadata.ComposableIndexTemplate;
1212
import org.elasticsearch.xcontent.XContentBuilder;
13+
import org.elasticsearch.xcontent.ToXContent;
1314
import org.elasticsearch.test.ESTestCase;
1415

1516
import java.io.IOException;
@@ -53,7 +54,7 @@ private static void toXContent(GetComposableIndexTemplatesResponse response, XCo
5354
builder.startObject();
5455
builder.field("name", e.getKey());
5556
builder.field("index_template");
56-
e.getValue().toXContent(builder, null);
57+
e.getValue().toXContent(builder, ToXContent.EMPTY_PARAMS);
5758
builder.endObject();
5859
}
5960
builder.endArray();

client/rest-high-level/src/test/java/org/elasticsearch/client/migration/GetFeatureUpgradeStatusResponseTests.java

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,14 @@ protected org.elasticsearch.action.admin.cluster.migration.GetFeatureUpgradeStat
4040
randomAlphaOfLengthBetween(3, 20),
4141
randomFrom(Version.CURRENT, Version.CURRENT.minimumCompatibilityVersion()),
4242
randomFrom(org.elasticsearch.action.admin.cluster.migration.GetFeatureUpgradeStatusResponse.UpgradeStatus.values()),
43-
randomList(4,
44-
() -> new org.elasticsearch.action.admin.cluster.migration.GetFeatureUpgradeStatusResponse.IndexVersion(
43+
randomList(
44+
4,
45+
() -> new org.elasticsearch.action.admin.cluster.migration.GetFeatureUpgradeStatusResponse.IndexInfo(
4546
randomAlphaOfLengthBetween(3, 20),
46-
randomFrom(Version.CURRENT, Version.CURRENT.minimumCompatibilityVersion())))
47+
randomFrom(Version.CURRENT, Version.CURRENT.minimumCompatibilityVersion()),
48+
null
49+
)
50+
)
4751
)),
4852
randomFrom(org.elasticsearch.action.admin.cluster.migration.GetFeatureUpgradeStatusResponse.UpgradeStatus.values())
4953
);
@@ -78,12 +82,12 @@ protected void assertInstances(
7882
assertThat(clientStatus.getIndexVersions(), hasSize(serverTestStatus.getIndexVersions().size()));
7983

8084
for (int j = 0; i < clientStatus.getIndexVersions().size(); i++) {
81-
org.elasticsearch.action.admin.cluster.migration.GetFeatureUpgradeStatusResponse.IndexVersion serverIndexVersion
85+
org.elasticsearch.action.admin.cluster.migration.GetFeatureUpgradeStatusResponse.IndexInfo serverIndexInfo
8286
= serverTestStatus.getIndexVersions().get(j);
8387
GetFeatureUpgradeStatusResponse.IndexVersion clientIndexVersion = clientStatus.getIndexVersions().get(j);
8488

85-
assertThat(clientIndexVersion.getIndexName(), equalTo(serverIndexVersion.getIndexName()));
86-
assertThat(clientIndexVersion.getVersion(), equalTo(serverIndexVersion.getVersion().toString()));
89+
assertThat(clientIndexVersion.getIndexName(), equalTo(serverIndexInfo.getIndexName()));
90+
assertThat(clientIndexVersion.getVersion(), equalTo(serverIndexInfo.getVersion().toString()));
8791
}
8892
}
8993
}

docs/reference/migration/apis/feature_upgrade.asciidoc

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ and to trigger an automated system upgrade that might potentially involve downti
2424
==== {api-prereq-title}
2525

2626
* If the {es} {security-features} are enabled, you must have the `manage`
27-
<<privileges-list-cluster,cluster privilege>> to use this API. (TODO: true?)
27+
<<privileges-list-cluster,cluster privilege>> to use this API.
2828

2929
[[feature-upgrade-api-example]]
3030
==== {api-examples-title}
@@ -46,79 +46,80 @@ Example response:
4646
{
4747
"feature_name" : "async_search",
4848
"minimum_index_version" : "8.0.0",
49-
"upgrade_status" : "NO_UPGRADE_NEEDED",
49+
"migration_status" : "NO_MIGRATION_NEEDED",
5050
"indices" : [ ]
5151
},
5252
{
5353
"feature_name" : "enrich",
5454
"minimum_index_version" : "8.0.0",
55-
"upgrade_status" : "NO_UPGRADE_NEEDED",
55+
"migration_status" : "NO_MIGRATION_NEEDED",
5656
"indices" : [ ]
5757
},
5858
{
5959
"feature_name" : "fleet",
6060
"minimum_index_version" : "8.0.0",
61-
"upgrade_status" : "NO_UPGRADE_NEEDED",
61+
"migration_status" : "NO_MIGRATION_NEEDED",
6262
"indices" : [ ]
6363
},
6464
{
6565
"feature_name" : "geoip",
6666
"minimum_index_version" : "8.0.0",
67-
"upgrade_status" : "NO_UPGRADE_NEEDED",
67+
"migration_status" : "NO_MIGRATION_NEEDED",
6868
"indices" : [ ]
6969
},
7070
{
7171
"feature_name" : "kibana",
7272
"minimum_index_version" : "8.0.0",
73-
"upgrade_status" : "NO_UPGRADE_NEEDED",
73+
"migration_status" : "NO_MIGRATION_NEEDED",
7474
"indices" : [ ]
7575
},
7676
{
7777
"feature_name" : "logstash_management",
7878
"minimum_index_version" : "8.0.0",
79-
"upgrade_status" : "NO_UPGRADE_NEEDED",
79+
"migration_status" : "NO_MIGRATION_NEEDED",
8080
"indices" : [ ]
8181
},
8282
{
8383
"feature_name" : "machine_learning",
8484
"minimum_index_version" : "8.0.0",
85-
"upgrade_status" : "NO_UPGRADE_NEEDED",
85+
"migration_status" : "NO_MIGRATION_NEEDED",
8686
"indices" : [ ]
8787
},
8888
{
8989
"feature_name" : "searchable_snapshots",
9090
"minimum_index_version" : "8.0.0",
91-
"upgrade_status" : "NO_UPGRADE_NEEDED",
91+
"migration_status" : "NO_MIGRATION_NEEDED",
9292
"indices" : [ ]
9393
},
9494
{
9595
"feature_name" : "security",
9696
"minimum_index_version" : "8.0.0",
97-
"upgrade_status" : "NO_UPGRADE_NEEDED",
97+
"migration_status" : "NO_MIGRATION_NEEDED",
9898
"indices" : [ ]
9999
},
100100
{
101101
"feature_name" : "tasks",
102102
"minimum_index_version" : "8.0.0",
103-
"upgrade_status" : "NO_UPGRADE_NEEDED",
103+
"migration_status" : "NO_MIGRATION_NEEDED",
104104
"indices" : [ ]
105105
},
106106
{
107107
"feature_name" : "transform",
108108
"minimum_index_version" : "8.0.0",
109-
"upgrade_status" : "NO_UPGRADE_NEEDED",
109+
"migration_status" : "NO_MIGRATION_NEEDED",
110110
"indices" : [ ]
111111
},
112112
{
113113
"feature_name" : "watcher",
114114
"minimum_index_version" : "8.0.0",
115-
"upgrade_status" : "NO_UPGRADE_NEEDED",
115+
"migration_status" : "NO_MIGRATION_NEEDED",
116116
"indices" : [ ]
117117
}
118118
],
119-
"upgrade_status" : "NO_UPGRADE_NEEDED"
119+
"migration_status" : "NO_MIGRATION_NEEDED"
120120
}
121121
--------------------------------------------------
122+
// TESTRESPONSE[s/"minimum_index_version" : "8.0.0"/"minimum_index_version" : $body.$_path/]
122123

123124
This response tells us that Elasticsearch security needs its internal
124125
indices upgraded before we can upgrade the cluster to 8.0.
@@ -143,6 +144,7 @@ Example response:
143144
]
144145
}
145146
--------------------------------------------------
147+
// TESTRESPONSE[skip: can't actually upgrade system indices in these tests]
146148

147149
This tells us that the security index is being upgraded. To check the
148150
overall status of the upgrade, call the endpoint with GET.

docs/reference/migration/migrate_8_0.asciidoc

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ coming[8.0.0]
2525
* <<breaking_80_ingest_changes>>
2626
* <<breaking_80_java_changes>>
2727
* <<breaking_80_mappings_changes>>
28-
* <<breaking_80_monitoring_changes>>
2928
* <<breaking_80_network_changes>>
3029
* <<breaking_80_node_changes>>
3130
* <<breaking_80_packaging_changes>>
@@ -128,7 +127,6 @@ include::migrate_8_0/indices.asciidoc[]
128127
include::migrate_8_0/ingest.asciidoc[]
129128
include::migrate_8_0/java.asciidoc[]
130129
include::migrate_8_0/mappings.asciidoc[]
131-
include::migrate_8_0/monitoring.asciidoc[]
132130
include::migrate_8_0/network.asciidoc[]
133131
include::migrate_8_0/node.asciidoc[]
134132
include::migrate_8_0/packaging.asciidoc[]

docs/reference/migration/migrate_8_0/monitoring.asciidoc

Lines changed: 0 additions & 47 deletions
This file was deleted.

docs/reference/migration/migrate_8_0/security.asciidoc

Lines changed: 35 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,37 @@ Specifying this setting in a transport profile in `elasticsearch.yml` will
165165
result in an error on startup.
166166
====
167167

168+
[discrete]
169+
[[saml-realm-nameid-changes]]
170+
.The `nameid_format` SAML realm setting no longer has a default value.
171+
[%collapsible]
172+
====
173+
*Details* +
174+
In SAML, Identity Providers (IdPs) can either be explicitly configured to
175+
release a `NameID` with a specific format, or configured to attempt to conform
176+
with the requirements of a Service Provider (SP). The SP declares its
177+
requirements in the `NameIDPolicy` element of a SAML Authentication Request.
178+
In {es}, the `nameid_format` SAML realm setting controls the `NameIDPolicy`
179+
value.
180+
181+
Previously, the default value for `nameid_format` was
182+
`urn:oasis:names:tc:SAML:2.0:nameid-format:transient`. This setting created
183+
authentication requests that required the IdP to release `NameID` with a
184+
`transient` format.
185+
186+
The default value has been removed, which means that {es} will create SAML Authentication Requests by default that don't put this requirement on the
187+
IdP. If you want to retain the previous behavior, set `nameid_format` to
188+
`urn:oasis:names:tc:SAML:2.0:nameid-format:transient`.
189+
190+
*Impact* +
191+
If you currently don't configure `nameid_format` explicitly, it's possible
192+
that your IdP will reject authentication requests from {es} because the requests
193+
do not specify a `NameID` format (and your IdP is configured to expect one).
194+
This mismatch can result in a broken SAML configuration. If you're unsure whether
195+
your IdP is explicitly configured to use a certain `NameID` format and you want to retain current behavior
196+
, try setting `nameid_format` to `urn:oasis:names:tc:SAML:2.0:nameid-format:transient` explicitly.
197+
====
198+
168199
[discrete]
169200
[[ssl-validation-changes]]
170201
===== SSL/TLS configuration validation
@@ -287,7 +318,7 @@ on startup.
287318

288319
[discrete]
289320
[[ssl-misc-changes]]
290-
===== Other SSL/TLS changes
321+
===== Other SSL/TLS changes
291322

292323
.PKCS#11 keystores and trustores cannot be configured in `elasticsearch.yml`
293324
[%collapsible]
@@ -307,7 +338,7 @@ Use of a PKCS#11 keystore or truststore as the JRE's default store is not affect
307338
308339
*Impact* +
309340
If you have a PKCS#11 keystore configured within your `elasticsearch.yml` file, you must remove that
310-
configuration and switch to a supported keystore type, or configure your PKCS#11 keystore as the
341+
configuration and switch to a supported keystore type, or configure your PKCS#11 keystore as the
311342
JRE default store.
312343
====
313344

@@ -360,6 +391,7 @@ renamed to better reflect its intended use.
360391
Assign users with the `kibana_user` role to the `kibana_admin` role.
361392
Discontinue use of the `kibana_user` role.
362393
====
394+
363395
// end::notable-breaking-changes[]
364396

365397
// These are non-notable changes
@@ -373,7 +405,7 @@ Discontinue use of the `kibana_user` role.
373405
[%collapsible]
374406
====
375407
*Details* +
376-
If `xpack.security.fips_mode.enabled` is true (see <<fips-140-compliance>>),
408+
If `xpack.security.fips_mode.enabled` is true (see <<fips-140-compliance>>),
377409
the value of `xpack.security.authc.password_hashing.algorithm` now defaults to
378410
`pbkdf2_stretch`.
379411

0 commit comments

Comments
 (0)