-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
server: remove contention event registry from baseStatusServer
Previously, baseStatusServer holds a reference to contention.Registry. This reference of contention.Registry is used to power the /ListContentionEvents endpoint. However, this is not ideal for two reasons: 1. baseStatusServer already holds a reference to *server.SQLServer, which in turn contains contention.Registry through its ExecutorConfig field. This means that there's no good reason to have another field in baseStatusServer to hold this additional reference. 2. The ongoing contention event registry work will make contention registry depend on status server to perform transaction ID resolution protocol. As it stand today, the status server's construction depends on the creation of contention.Registry. By introducing transaction ID resolution protocol into contention.Registry, we will be introducing a cyclical reference, which can lead to ugly API design. This commit removes the baseStatusServer's reference on contention.Registry, and instead directly fetching from executor config. Release note: None
- Loading branch information
Showing
4 changed files
with
27 additions
and
33 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