Skip to content
This repository has been archived by the owner on Aug 12, 2024. It is now read-only.

Refactor the main reconciliation logic for the plain provisioner's BI controller #283

Open
timflannagan opened this issue Apr 29, 2022 · 2 comments
Assignees
Labels
lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release.
Milestone

Comments

@timflannagan
Copy link
Contributor

Goal: refactor the main Reconcile method for the BI controller into individual methods to help reduce the amount of complexity (and overall LoC) for the driver function.

Right now the plain provisioner's main Reconcile method is reaching a complexity threshold which makes it difficult to read, reason about, and extend when interacting with that part of the codebase.

The controller is responsible for the following control flow:

  • Get the BI resource from the informer cache
  • Check whether the corresponding Bundle resource is reporting an Unpacked phase
  • Get the unpacked Bundle contents from the storage layer's cache
  • Build up a helm chart based on the desired set of client.Object resources
  • Ensure the release state (e.g. install or upgrade) logic is performed
  • Ensure the desired objects have a dynamic watch present in the internal mapping of GVK watches

As the BI API surface gets extended to support things like label selection (#94) or embedded Bundles (#73), we'll need to introduce more complexity into this controller.

@timflannagan timflannagan added the priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. label Apr 29, 2022
@timflannagan timflannagan added this to the 0.5 milestone Apr 29, 2022
@timflannagan timflannagan modified the milestones: v0.5.0, v0.6.0 May 9, 2022
@akihikokuroda akihikokuroda self-assigned this May 18, 2022
@exdx exdx modified the milestones: v0.6.0, v0.7.0 Jun 24, 2022
@exdx
Copy link
Member

exdx commented Jul 18, 2022

Moving to v0.8 milestone. Looks like this issue has been carried from release to release for a while -- let's try to get it merged

@exdx exdx modified the milestones: v0.7.0, v0.8.0 Jul 18, 2022
@akihikokuroda akihikokuroda modified the milestones: v0.8.0, v0.9.0 Aug 8, 2022
@timflannagan timflannagan modified the milestones: v0.9.0, backlog Aug 18, 2022
@github-actions
Copy link

This issue has become stale because it has been open 60 days with no activity. The maintainers of this repo will remove this label during issue triage or it will be removed automatically after an update. Adding the lifecycle/frozen label will cause this issue to ignore lifecycle events.

@github-actions github-actions bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Oct 18, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants