Skip to content

Conversation

@fcofdez
Copy link
Contributor

@fcofdez fcofdez commented Nov 26, 2025

This commit changes SyntheticIdField to be an indexed field but with an empty TokenStream to ensure that there's minimal work done while indexing synthetic _id fields. The reason for the change is that Lucene ensures that the schema is consistent across all the segments and new documents, and before we used to modify the _id FieldInfo at read time to ensure that the field is considered as indexed to allow update/deletes, but once a new document is added, it will have IndexOptions.NONE and Lucene would throw an exception.

In addition to such changes, there's some small code reorganization and simplification.

This PR depends on #138515

@fcofdez fcofdez requested review from burqen and tlrx November 26, 2025 14:57
@fcofdez fcofdez added >enhancement :Distributed Indexing/Distributed A catch all label for anything in the Distributed Indexing Area. Please avoid if you can. Team:Distributed Indexing Meta label for Distributed Indexing team labels Nov 26, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-distributed-indexing (Team:Distributed Indexing)

@elasticsearchmachine
Copy link
Collaborator

Hi @fcofdez, I've created a changelog YAML for you.

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

Labels

:Distributed Indexing/Distributed A catch all label for anything in the Distributed Indexing Area. Please avoid if you can. >enhancement Team:Distributed Indexing Meta label for Distributed Indexing team v9.3.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants