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

Transition from KEB API to KIM Runtime CR #89

Open
a-thaler opened this issue Sep 20, 2024 · 1 comment
Open

Transition from KEB API to KIM Runtime CR #89

a-thaler opened this issue Sep 20, 2024 · 1 comment

Comments

@a-thaler
Copy link
Collaborator

a-thaler commented Sep 20, 2024

Description

KMC is currently relying on KEB as a dependency to retrieve the list of billable clusters, see also the arch diagram.

Hereby, a REST API gets used which was not designed for that scenario and is cumbersome to use. It requires custom paging logic and complicated filtering.

Instead of relying on KEB as the source of truth on if a cluster should be billed effectively, the new infrastructure manager (KIM) with its Runtime CRD should be used. The API can be easily watched by the native kube client of the KMC controller and newly added or removed clusters can be easily observed.

Also that change will be an enabler for #90

Goal: Adjust the KMC logic to not rely on the KEB API anymore, but instead use the Runtime API of KIM.

Criterias

  • There is no dependency to KEB anymore (updated arch diagram)
  • RBAC settings have new read permissions for Runtime CR
  • The cluster discovery logic is based on Runtime resources
  • It is aligned on what criterias to watch for billing

Remarks
The current status of a Runtime CR reflects the gardener shoot status mainly, which will not be sufficient to decide on the "to bill or not to bill" decision.

The decision when to start billing should be:

  • The user requested a cluster -> Runtime CR exists
  • The cluster is ready to use / user can access it -> Runtime CR state was "ready" once

The decision when to stop billing should be:

  • The user requested to delete the cluster -> Runtime CR is requested to be deleted

In best case, KIM will document in the CR when the cluster was ready for the first time and when it was requested to be deleted, maybe in additional status attributes, like:

  • provisioned_at
  • deletion_requested_at

That attributes will be also helpful later on when deciding to do a final deletion after a hibernation grace period.

Copy link

This issue has been automatically marked as stale due to the lack of recent activity. It will soon be closed if no further activity occurs.
Thank you for your contributions.

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