-
Notifications
You must be signed in to change notification settings - Fork 92
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[changelog] Fix metadata refresh deadlock scenario (#1536)
* [changelog] Fix metadata refresh deadlock scenario There exists a deadlocking race condition when a version swap happens. The version swap data change listener locks itself and then proceeds with the version swap on the consumer. However, other function calls would also call refresh() on the metadata repository. This in turn would trigger more callbacks on the data change listener. In some scenarios, this can cause deadlocking. This change makes sure that we no longer leverage manual refreshes and instead let the whole process get driven by the scheduled metadata refresh. This also makes the refresh time configurable, and seems to speed up tests (yay!) as there were frequent retries on consuming events as we had to wait for the version swap to happen internally before we could consume the events we expected.
- Loading branch information
Showing
5 changed files
with
175 additions
and
125 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.