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

[BUG] Index mapping updates do not get replicated #1430

Open
alexmm-amzn opened this issue Aug 26, 2024 · 2 comments
Open

[BUG] Index mapping updates do not get replicated #1430

alexmm-amzn opened this issue Aug 26, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@alexmm-amzn
Copy link

What is the bug?

Updating an index mapping on the cluster leader does not get replicated in many circumstances.

The cluster replication plugin periodically checks for index mapping updates but only applies them if an already existing property mapping known to the follower gets modified.

Code reference:

This breaks index mapping updates that only add mappings for new properties or modify dynamic mappings. If an existing property mapping gets modified however the replication will apply the entire mappings - including dynamic mappings.

Possible workaround: Modify also an existing property mapping, e.g. add a meta field to the property mapping.

How can one reproduce the bug?
Steps to reproduce the behavior:

  1. Create an index with at least one property mapping on the cluster leader.
  2. Enable the cluster replication and wait until the index gets replicated to the follower.
  3. Add new property to the index mappings on the cluster leader.
  4. Wait and see that nothing gets replicated.
  5. Modify the existing property from step 1 by adding a "meta": {"force": "true"}
  6. Wait and see that the mapping gets replicated.

What is the expected behavior?

Any index mapping update on the cluster leader should get replicated with no workarounds required.

What is your host/environment?

  • OS: 2.11 and 2.13

Do you have any screenshots?
N/A

Do you have any additional context?
N/A

@alexmm-amzn alexmm-amzn added bug Something isn't working untriaged labels Aug 26, 2024
@dblock dblock removed the untriaged label Sep 16, 2024
@dblock
Copy link
Member

dblock commented Sep 16, 2024

[Catch All Triage - 1, 2, 3, 4, 5]

@dblock dblock added the enhancement New feature or request label Sep 16, 2024
@dblock
Copy link
Member

dblock commented Sep 16, 2024

@alexmm-amzn Thanks for digging into the code. Want to give writing a test that reproduces this problem a try? Maybe fix the issue?

@dblock dblock removed the enhancement New feature or request label Sep 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants