Skip to content
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

Only fetch mapping updates when necessary #33182

Merged
merged 3 commits into from
Aug 28, 2018

Conversation

jasontedor
Copy link
Member

Today we fetch the mapping from the leader and apply it as a mapping update whenever the index metadata version on the leader changes. Yet, the index metadata can change for many reasons other than a mapping update (e.g., settings updates, adding an alias, or a replica being promoted to a primary among many other reasons). This commit builds on the addition of a mapping version to the index metadata to only fetch mapping updates when the mapping version increases. This reduces the number of these fetches and application of mappings on the follower to the bare minimum.

Relates #33147

Today we fetch the mapping from the leader and apply it as a mapping
update whenever the index metadata version on the leader changes. Yet,
the index metadata can change for many reasons other than a mapping
update (e.g., settings updates, adding an alias, or a replica being
promoted to a primary among many other reasons). This commit builds on
the addition of a mapping version to the index metadata to only fetch
mapping updates when the mapping version increases. This reduces the
number of these fetches and application of mappings on the follower to
the bare minimum.
@jasontedor jasontedor added review :Distributed Indexing/CCR Issues around the Cross Cluster State Replication features labels Aug 27, 2018
@jasontedor jasontedor requested review from martijnvg and dnhatn August 27, 2018 18:09
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-distributed

@jasontedor
Copy link
Member Author

@elasticmachine run the oss docs tests

@dnhatn
Copy link
Member

dnhatn commented Aug 27, 2018

@jasontedor I am fixing the oss doc issue.

Copy link
Member

@dnhatn dnhatn left a comment

Choose a reason for hiding this comment

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

LGTM.

@jasontedor
Copy link
Member Author

Okay, thanks @dnhatn.

* ccr:
  DOCS: Make ellipsis optional in /cat/thread_pool (elastic#33186)
Copy link
Member

@martijnvg martijnvg left a comment

Choose a reason for hiding this comment

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

LGTM

@jasontedor jasontedor merged commit cd91992 into elastic:ccr Aug 28, 2018
jasontedor added a commit that referenced this pull request Aug 28, 2018
Today we fetch the mapping from the leader and apply it as a mapping
update whenever the index metadata version on the leader changes. Yet,
the index metadata can change for many reasons other than a mapping
update (e.g., settings updates, adding an alias, or a replica being
promoted to a primary among many other reasons). This commit builds on
the addition of a mapping version to the index metadata to only fetch
mapping updates when the mapping version increases. This reduces the
number of these fetches and application of mappings on the follower to
the bare minimum.
@jasontedor jasontedor deleted the ccr-mapping-version branch August 28, 2018 10:10
jasontedor added a commit to jasontedor/elasticsearch that referenced this pull request Aug 28, 2018
* ccr:
  Only fetch mapping updates when necessary (elastic#33182)
jasontedor added a commit to martijnvg/elasticsearch that referenced this pull request Aug 28, 2018
* ccr:
  Fix ShardFollowNodeTask.Status equals and hash code (elastic#33189)
  Make soft-deletes settings final (elastic#33172)
  Only fetch mapping updates when necessary (elastic#33182)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Distributed Indexing/CCR Issues around the Cross Cluster State Replication features
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants