-
Notifications
You must be signed in to change notification settings - Fork 24.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Simplify dynamic mappings updates. #10720
Simplify dynamic mappings updates. #10720
Conversation
// hand putting the mapping would start the river, which expects | ||
// to find a _meta document | ||
// So we have no choice but to index first and send mappings afterwards | ||
indexService.mapperService().merge(indexRequest.type(), new CompressedString(update.toBytes()), true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we assigne indexService.mapperService()
to a var? just to remove the chaining :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok will do
left a couple of comments |
LGTM I think we should add the UUID in a second step in a followup issue |
While dynamic mappings updates are using the same code path as updates from the API when applied on a data node since elastic#10593, they were still using a different code path on the master node. This commit makes dynamic updates processed the same way as updates from the API, which also seems to do a better way at acknowledgements (I could not reproduce the ConcurrentDynamicTemplateTests failure anymore). It also adds more checks, like for instance that indexing on replicas should not trigger dynamic mapping updates since they should have been handled on the primary before. Close elastic#10720
9301b56
to
c6cdf77
Compare
Mappings: simplify dynamic mappings updates. Close #10720
While dynamic mappings updates are using the same code path as updates from the
API when applied on a data node since #10593, they were still using a different
code path on the master node. This commit makes dynamic updates processed the
same way as updates from the API, which also seems to do a better way at
acknowledgements (I could not reproduce the ConcurrentDynamicTemplateTests
failure anymore). It also adds more checks, like for instance that indexing on
replicas should not trigger dynamic mapping updates since they should have been
handled on the primary before.