WIP: Add server disk statistics worker
What does this MR do?
This MR adds a service class that implements an execute method called by a new worker class that is designed to collect disk usage and availability statistics from a Gitaly grpc for each configured sharded Gitaly storage server.
These disk statistics are used in a heuristic to conditionally invoke a worker which is responsible for "re-balancing" git repositories between the configured Gitaly storage servers.
WIP Todos:
-
Rebase with master once the gitaly grpc
stubs for gitaly!1620 (merged), and the gitaly gem version updates for !22226 (merged), have been included in themaster
branch ofgitlab-org/gitlab
. -
Flesh out spec
tests to cover all added code units. -
Implement git repository shard re-balancing worker. This perhaps may be accomplished in a separate MR.
Does this MR meet the acceptance criteria?
Conformity
-
Changelog entry -
Documentation (if required) -
Code review guidelines -
Merge request performance guidelines -
Style guides - [-] Database guides
-
Separation of EE specific content
Availability and Testing
What risks does this change pose?
This change presents some additional risks with because it will add some automated processing of storage repositories in sharded gitaly environments.
How might it affect the quality/performance of the product?
There should not be any significant performance impact.
What additional test coverage or changes to tests will be needed?
There will be additional spec tests for each added code unit.
Will it require cross-browser testing?
No.
-
Review and add/update tests for this feature/bug. Consider all test levels. See the Test Planning Process. - [-] Tested in all supported browsers
Security
If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:
- [-] Label as security and @ mention
@gitlab-com/gl-security/appsec
- [-] The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
- [-] Security reports checked/validated by a reviewer from the AppSec team