Skip to content

Conversation

@jdconrad
Copy link
Contributor

This change does two things:

  1. Adds the current transport version to index metadata whenever a new index is created.
  2. Updates the deprecation API to include indices that have mapped percolator fields based on the previously mentioned transport version. We want all percolator indices to be re-indexed to at least the previous major's latest minor so we can continue to remove older transport versions as part of our maintenance cycle.

…c#137548)

This change modifies the deprecation API to check for
any indices prior to 9.latest that have percolator fields in
the mappings. Any that do are then returned as
required to be reindexed or deleted. Read-only is
excluded as this would not fix the underlying
transport version issue.

Note this change only concerns user created
indices. System indices will need to be addressed
separately as part of the migration API, but should
be able to share code.

ES-13234
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra (Team:Core/Infra)

@jdconrad jdconrad added the auto-backport Automatically create backport pull requests when merged label Nov 14, 2025

private static boolean transportVersionBeforeCurrentMinorRelease(IndexMetadata indexMetadata) {
// We divide each transport version by 1000 to get the base id.
return indexMetadata.getTransportVersion().id() / 1000 < TransportVersion.current().id() / 1000;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rjernst is there a better way to calculate this? Right now this is just convention, right?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm happy to update this in another PR, but given limited time, I'm going to get rolling on the backports.

Thanks for the review!

@jdconrad jdconrad merged commit 73a9348 into elastic:main Nov 17, 2025
34 checks passed
@elasticsearchmachine
Copy link
Collaborator

💔 Backport failed

Status Branch Result
8.19 Commit could not be cherrypicked due to conflicts
9.1 Commit could not be cherrypicked due to conflicts
The backport operation could not be completed due to the following error:
An unhandled error occurred. Please consult the logs

You can use sqren/backport to manually backport by running backport --upstream elastic/elasticsearch --pr 138118

jdconrad added a commit to jdconrad/elasticsearch that referenced this pull request Nov 17, 2025
…8118)

This change modifies the deprecation API to check for
any indices prior to 9.latest that have percolator fields in
the mappings. Any that do are then returned as
required to be reindexed or deleted. Read-only is
excluded as this would not fix the underlying
transport version issue.

Note this change only concerns user created
indices. System indices will need to be addressed
separately as part of the migration API, but should
be able to share code.

ES-13234
jdconrad added a commit to jdconrad/elasticsearch that referenced this pull request Nov 17, 2025
…8118)

This change modifies the deprecation API to check for
any indices prior to 9.latest that have percolator fields in
the mappings. Any that do are then returned as
required to be reindexed or deleted. Read-only is
excluded as this would not fix the underlying
transport version issue.

Note this change only concerns user created
indices. System indices will need to be addressed
separately as part of the migration API, but should
be able to share code.

ES-13234
elasticsearchmachine pushed a commit that referenced this pull request Nov 17, 2025
…138192)

Backport to [9.2] of 
#138118

This change modifies the deprecation API to check for any indices prior
to 9.latest that have percolator fields in the mappings. Any that do are
then returned as required to be reindexed or deleted. Read-only is
excluded as this would not fix the underlying transport version issue.

Note this change only concerns user created indices. System indices will
need to be addressed separately as part of the migration API, but should
be able to share code.

ES-13234
elasticsearchmachine pushed a commit that referenced this pull request Nov 17, 2025
…138197)

Backport to [9.1] of
#138118

This change modifies the deprecation API to check for any indices prior
to 9.latest that have percolator fields in the mappings. Any that do are
then returned as required to be reindexed or deleted. Read-only is
excluded as this would not fix the underlying transport version issue.

Note this change only concerns user created indices. System indices will
need to be addressed separately as part of the migration API, but should
be able to share code.

ES-13234
jdconrad added a commit to jdconrad/elasticsearch that referenced this pull request Nov 17, 2025
…8118)

This change modifies the deprecation API to check for
any indices prior to 9.latest that have percolator fields in
the mappings. Any that do are then returned as
required to be reindexed or deleted. Read-only is
excluded as this would not fix the underlying
transport version issue.

Note this change only concerns user created
indices. System indices will need to be addressed
separately as part of the migration API, but should
be able to share code.

ES-13234
elasticsearchmachine pushed a commit that referenced this pull request Nov 18, 2025
…8118) (#138200)

Backport to [8.19] of
#138118

This change modifies the deprecation API to check for any indices prior
to 9.latest that have percolator fields in the mappings. Any that do are
then returned as required to be reindexed or deleted. Read-only is
excluded as this would not fix the underlying transport version issue.

Note this change only concerns user created indices. System indices will
need to be addressed separately as part of the migration API, but should
be able to share code.

ES-13234
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-backport Automatically create backport pull requests when merged backport pending :Core/Infra/Transport API Transport client API >non-issue Team:Core/Infra Meta label for core/infra team v8.19.8 v9.1.8 v9.2.2 v9.3.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants