Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Decouple check flow code from the checks #82

Open
cldmstr opened this issue Mar 17, 2023 · 0 comments
Open

Decouple check flow code from the checks #82

cldmstr opened this issue Mar 17, 2023 · 0 comments

Comments

@cldmstr
Copy link
Member

cldmstr commented Mar 17, 2023

Currently, the flow implemented by livelint checks a deployment and expects it to have a service and an ingress. Any other case will fail. To prepare the code for being able to implement other flows or checks, the flow (e.g. which checks are run in which order and what state of a specific check either calls for another check or is a leaf in the check flow chart) should be decoupled from the checks themselves and from the UI. the RunChecks(...) function currently has 3 responsibilities: 1. load data from kubernetes 2. run checks in a specific order 3. communicate with the user. These responsibilities should be distributed to different components.

  1. Data loading
    So that the checks themselves can work in an efficient manner, this will also require a kind of decoupled kubernetes resource reading and caching mechanism, so that the checks can get the required information, but so that not every check

  2. Different flow implementations should be possible so that the available checks can be easily extended (i.e. deployments without service, just pods, ingress, etc.)

  3. Errors or communication should be run over a standard interface where the flow does not need to know the exact form that user interaction takes or even if there is any kind of interaction. Check results and flow state should be continually reported to a standard interface.

@cldmstr cldmstr changed the title Create multiple check flows Decouple check flow code from the checks Mar 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant