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

[8.17](backport #4171) Remove race condition when accessing remote bulker map #4188

Merged
merged 1 commit into from
Dec 9, 2024

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Dec 6, 2024

What is the problem this PR solves?

Remove a race condition/bug that may occur when remote ES outputs are used.

How does this PR solve the problem?

Use the remoteOutputMutex whenever accessing the bulkerMap.
Change GetBulkerMap to return a copy of the map so that remote output health will not conflict with adding/removing a bulker from the map.

Design Checklist

  • I have ensured my design is stateless and will work when multiple fleet-server instances are behind a load balancer.
  • I have or intend to scale test my changes, ensuring it will work reliably with 100K+ agents connected.
  • I have included fail safe mechanisms to limit the load on fleet-server: rate limiting, circuit breakers, caching, load shedding, etc.

Checklist

  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have made corresponding change to the default configuration files
  • I have added tests that prove my fix is effective or that my feature works
  • I have added an entry in ./changelog/fragments using the changelog tool

Related issues

Use the remoteOutputMutex whenever accessing the bulkerMap.
Change GetBulkerMap to return a copy of the map so that remote output health will not conflict with adding/removing a bulker from the map.

(cherry picked from commit 924ea07)
@mergify mergify bot added the backport label Dec 6, 2024
@mergify mergify bot requested a review from a team as a code owner December 6, 2024 23:32
@mergify mergify bot requested review from pkoutsovasilis and swiatekm December 6, 2024 23:32
Copy link
Contributor Author

mergify bot commented Dec 9, 2024

This pull request has not been merged yet. Could you please review and merge it @michel-laterman? 🙏

@michel-laterman michel-laterman merged commit 72db3b5 into 8.17 Dec 9, 2024
8 checks passed
@michel-laterman michel-laterman deleted the mergify/bp/8.17/pr-4171 branch December 9, 2024 17:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants