-
Notifications
You must be signed in to change notification settings - Fork 64
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: refactoring component structure (#1044)
This PR refactors the core package by restructuring the components responsible for managing the subscriptions, as well as the creation of sync sources. The following changes have been made: - Renamed `sync-store` package to `subscriptions`. This has been done to avoid confusion because we already have a `sync`, and a `store`. package. Within the package, the `SyncStore`. has been renamed to `subscriptions.Manager`, which should reflect its responsibility in a better way. Also, the `syncHandler` has been renamed to `multiplexer`, as this one is responsible for sending updates of a certain target to all subscribers - `syncHandler` was a bit too generic in my opinion. - Moved the `GetSyncSourceFromURI` method to a new package, `sync/builder`, to remove the responsibility of building concrete sync sources from the subscription manager - Moved the logic of retrieving the K8s client config to the sync builder. Previously, this was done in the `runtime` package by calling the respective methods for the config retrieval provided by the `sync/kubernetes` package and then handing that config back to the initialization of the `K8sSync`. Note: This step can potentially be done in a separate PR, if so desired. --------- Signed-off-by: Florian Bacher <florian.bacher@dynatrace.com> Co-authored-by: Giovanni Liva <giovanni.liva@dynatrace.com>
- Loading branch information
Showing
21 changed files
with
1,035 additions
and
757 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
Oops, something went wrong.