Cleanup and refactor the controller after replacing the generator functions
NOTE: This is part of refactoring that is listed in #72 (closed)
This MR rolls out the following changes:
- Remove replacement tests, i.e.
controllers/gitlab/replace_*_test.go
. - Remove
DEPRECATED
generator functions and the files that contained them , e.g.controllers/gitlab/configmaps.go
, along with unused utilities fromcontrollers/gitlab
package. - Rename
controllers/gitlab/xyz_helpers.go
tocontrollers/gitlab/xyz.go
, e.g.gitaly_helpers.go
togitaly.go
. - Merge
controllers/helpers
package intocontrollers/gitlab
. - Move any remaining generator function, e.g.
Minio*
orBucketCreationJob
, and their dependencies and required utilities tocontrollers/internal
package. - Move utilities from
controllers/utils
tocontrollers/internal
and removed unused code fromcontrollers/utils
. - Merge controller helpers,
controllers/helpers.go
, with the controller. - Remove unused GitLab assets for generator functions.
- Updates RBAC and bundled CRD manifest to reflect the new changes in !110 (merged) and !118 (merged).
As a result of these changes:
- GitLab code is consolidated in
controllers/gitlab
package. - The initial MVP code is consolidated in
controllers/internal
package. -
controllers/gitlab
does not depend on any other MVP package, includingcontrollers/internal
. This will simplify the future refactoring. -
controllers/internal
still depends on some of the static assets in `hack - GitLab controller relies on both
controllers/gitlab
andcontrollers/internal
. - Backup and Runner controllers and their dependencies are not changed.
Closes #72 (closed)
Edited by Hossein Pursultani