-
Notifications
You must be signed in to change notification settings - Fork 569
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
fix(gateway): store followers and inactive nodes in sets #10255
Conversation
392fd87
to
95a4c0d
Compare
95a4c0d
to
1a29f63
Compare
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.
👍
Fix looks good. I added one comment about tests relating to waitUntil
vs Awaitility
. I only added in one place, but it applies to all the places you used waitUntil
.
🔧 One additional thing, as we are slowly, progressively migrating to Junit 5 (e.g. new things should be written with junit 5, assertJ, awaitility,e tc.), I would typically take the opportunity to migrate the whole test class (as a separate commit of course). I think it's perfectly fine you don't do this here as you're still just getting familiar with everything, but this is something I'd recommend in the future (when it's easy enough, of course).
Anyway, once you've addressed the Awaitility
comment, I don't think we need another review again (change is fairly straightforward), but ofc feel free to request one if you'd like :)
gateway/src/test/java/io/camunda/zeebe/gateway/topology/TopologyUpdateTest.java
Outdated
Show resolved
Hide resolved
Fully agree but also due to backporting labels I would leave the full junit5 migration of this class out of scope for now. Will replace all usages of |
Previous use of lists resulted in unbounded growth due to duplication of the same broker ids.
d90f0c8
to
dfb084a
Compare
gateway/src/test/java/io/camunda/zeebe/gateway/topology/TopologyUpdateTest.java
Outdated
Show resolved
Hide resolved
dfb084a
to
649d8fa
Compare
bors r+ |
10255: fix(gateway): store followers and inactive nodes in sets r=megglos a=megglos Previous use of lists resulted in unbounded growth due to duplication of the same broker ids. ## Description Replaces the usage of Lists to keep track of followers and inactiveNodes in the BrokerClusterState with Sets to prevent duplication on arbitrary metadata updates. ## Related issues closes #8724 Co-authored-by: Meggle (Sebastian Bathke) <sebastian.bathke@camunda.com>
Build failed: |
Is this your first flaky test? 🕵️ |
bors retry |
10255: fix(gateway): store followers and inactive nodes in sets r=megglos a=megglos Previous use of lists resulted in unbounded growth due to duplication of the same broker ids. ## Description Replaces the usage of Lists to keep track of followers and inactiveNodes in the BrokerClusterState with Sets to prevent duplication on arbitrary metadata updates. ## Related issues closes #8724 Co-authored-by: Meggle (Sebastian Bathke) <sebastian.bathke@camunda.com>
yes 😁 have you seen these go client tests failing before in this way? |
Not the Go clients, but it can happen that the partition is initially unhealthy on startup before becoming healthy asynchronously. So it could be again this issue (just speculating). Here the PR is mostly modifying the broker cluster state (so the topology from the broker point of view) - the question is, could it have an impact on the topology from the gateway point of view? I think your PR is probably not introducing a bug there and it's a test set up issue (or you did really uncover a bug 😄), so it's probably safe to merge. In this instance, we open a new flaky test issue, and based on the test would assign it to one of the team's project. |
Build failed: |
bors retry |
10255: fix(gateway): store followers and inactive nodes in sets r=megglos a=megglos Previous use of lists resulted in unbounded growth due to duplication of the same broker ids. ## Description Replaces the usage of Lists to keep track of followers and inactiveNodes in the BrokerClusterState with Sets to prevent duplication on arbitrary metadata updates. ## Related issues closes #8724 Co-authored-by: Meggle (Sebastian Bathke) <sebastian.bathke@camunda.com>
Build failed: |
bors retry |
Build succeeded: |
Successfully created backport PR #10276 for |
Successfully created backport PR #10277 for |
Previous use of lists resulted in unbounded growth due to duplication of the same broker ids.
Description
Replaces the usage of Lists to keep track of followers and inactiveNodes in the BrokerClusterState with Sets to prevent duplication on arbitrary metadata updates.
Related issues
closes #8724
Definition of Done
Not all items need to be done depending on the issue and the pull request.
Code changes:
backport stable/1.3
) to the PR, in case that fails you need to create backports manually.Testing:
Documentation:
Please refer to our review guidelines.