Skip to content

[8.x] Fix issues with ReinitializingSourceProvider (#118370)#118431

Merged
elasticsearchmachine merged 2 commits intoelastic:8.xfrom
martijnvg:backport/8.x/pr-118370
Dec 11, 2024
Merged

[8.x] Fix issues with ReinitializingSourceProvider (#118370)#118431
elasticsearchmachine merged 2 commits intoelastic:8.xfrom
martijnvg:backport/8.x/pr-118370

Conversation

@martijnvg
Copy link
Copy Markdown
Member

Backports the following commits to 8.x:

The previous fix to ensure that each thread uses its own SearchProvider wasn't good enough.  The read from `perThreadProvider` field could be stale and therefore returning a previous source provider.  Instead the source provider should be returned from `provider` local variable.

This change also addresses another issue, sometimes current docid goes backwards compared to last seen docid and this causes issue when synthetic source provider is used, as doc values can't advance backwards. This change addresses that by returning a new source provider if backwards docid is detected.

Closes elastic#118238
@martijnvg martijnvg added :StorageEngine/Mapping The storage related side of mappings >bug auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) backport Team:StorageEngine labels Dec 11, 2024
@martijnvg
Copy link
Copy Markdown
Member Author

@elasticmachine run elasticsearch-ci/part-3

@martijnvg
Copy link
Copy Markdown
Member Author

@elasticmachine update branch

@martijnvg
Copy link
Copy Markdown
Member Author

@elasticmachine run elasticsearch-ci/part-3

@elasticsearchmachine elasticsearchmachine merged commit e1d83e9 into elastic:8.x Dec 11, 2024
@martijnvg martijnvg deleted the backport/8.x/pr-118370 branch December 11, 2024 18:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) backport >bug :StorageEngine/Mapping The storage related side of mappings Team:StorageEngine v8.18.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants