-
Notifications
You must be signed in to change notification settings - Fork 91
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ref(project-cache): Split project cache into shared and private parts (…
…#4147) Makes the project cache concurrently accessible using a lockfree shared map. - Removes support for `no_cache` queries, they were not used for a long time and simplify the design (no need to make project accesses awaitable). - Removes support for the v2 project cache endpoint, v3 has been out for > 2 years. The PR also removed all project cache handling from the old (now called legacy) project cache and moved it to a newer, simplified project cache which only does the book-keeping for the actual project cache. The old Spool V1 implementation and some message handling remains in the legacy project cache. The spool v1 will eventually be removed, the other messages can now be replaced and no longer need to be messages and can be removed in follow up PRs. Some messages likes `ProcessMetrics` have already been removed. The garbage disposal has been removed, with the new organization we generate a lot less overall 'trash' which needs to be disposed as well as it is no longer necessary to offload the disposal to another thread, since the service itself has a lot less volume/work to do and service latency is no longer a major concern for stability. It is now possible to subscribe to project cache events, this is done using a tokio broadcast channel, the channel is inherently size limited, which is problematic, since currently subscribers cannot deal with lag and cannot miss any messages. To prevent this (until we have a better way), the channel is set to a maximum size which should theoretically be impossible to reach. This is more described in code itself. Functional changes: - Projects are only expired through the eviction mechanism, they are no longer expired on access, it's possible to configure Relay in a way where expired projects are used if the eviction interval is too long. To compensate for this, the config has been tuned. Ideally the eviction interval is shorter than the grace period.
- Loading branch information
Showing
37 changed files
with
2,198 additions
and
2,339 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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.