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

KIM Integration - redesign configuration after migration is done #1241

Open
1 of 5 tasks
jaroslaw-pieszka opened this issue Oct 2, 2024 · 4 comments
Open
1 of 5 tasks
Assignees
Labels
size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Comments

@jaroslaw-pieszka
Copy link
Contributor

jaroslaw-pieszka commented Oct 2, 2024

When we use KIM only, provisioner is no longer used, we need to simplify and unify configuration.

To many steps we pass separately input.Config and broker.KimConfig objects.

Phase 1 AC: 12.2024

Phase 2 AC: 01.2025

  • 1) we pass one configuration object to all steps that need it
  • 2) there are no longer provisioner related settings (this is in scope of different ticket)
  • 3) KIM migration related settings are removed
  • 4) some previously used settings become KIM related and possible should be moved to kim section
@jaroslaw-pieszka
Copy link
Contributor Author

Blocked till migration is done.

@jaroslaw-pieszka
Copy link
Contributor Author

Following configuration values should be migrated to kim section (are used to create Runtime CRs`:

  • Provisioner.KubernetesVersion
  • Provisioner.DefaultGardenerShootPurpose
  • Provisioner.MachineImage
  • Provisioner.MachineImageVersion
  • Provisioner.DefaultTrialProvider
  • Provisioner.MultiZoneCluster
  • Provisioner.ControlPlaneFailureTolerance

We could consider moving:

  • Broker.UseSmallerMachineTypes to kim section

Following values should be moved to other place (possible section with timeouts - there are more timeouts settings scattered):

  • Provisioner.ProvisioningTimeout
  • Provisioner.DeprovisioningTimeout
  • Provisioner.RuntimeResourceStepTimeout
  • Provisioner.ClusterUpdateStepTimeout

Following values should be removed (double check before actual removal):

  • Provisioner.URL
  • Provisioner.TrialNodesNumber
  • Provisioner.AutoUpdateKubernetesVersion
  • Provisioner.AutoUpdateMachineImageVersion
  • Provisioner.EnableShootAndSeedSameRegion

Removal is blocked until provisioner is decommissioned and only KIM is driving/controlling the process.

@jaroslaw-pieszka
Copy link
Contributor Author

jaroslaw-pieszka commented Oct 14, 2024

This is blocked by #1187 and #1298

@PK85 PK85 added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Dec 4, 2024
@KsaweryZietara KsaweryZietara self-assigned this Dec 13, 2024
@KsaweryZietara
Copy link
Contributor

KsaweryZietara commented Dec 16, 2024

management-plane-config(https://github.tools.sap/kyma/management-plane-config/pull/5959):

gardener:
  defaultShootPurpose:
  defaultTrialProvider:
  kubernetesVersion:
  machineImage:
  machineImageVersion:
  multiZoneCluster:
  controlPlaneFailureTolerance:
timeouts:
  provisioning:
  deprovisioning:
  gardenerClusterStep:
  runtimeResourceStep:
  clusterUpdateStep:
  checkRuntimeResourceDeletionStep:
  kymaResourceDeletion:

deployment.yaml:

- name: APP_BROKER_KIM_CONFIG_DEFAULT_GARDENER_SHOOT_PURPOSE
  value: "{{ .Values.gardener.defaultShootPurpose }}"
- name: APP_BROKER_KIM_CONFIG_DEFAULT_TRIAL_PROVIDER
  value: "{{ .Values.gardener.defaultTrialProvider }}"
- name: APP_BROKER_KIM_CONFIG_KUBERNETES_VERSION
  value: "{{ .Values.gardener.kubernetesVersion }}"
- name: APP_BROKER_KIM_CONFIG_MACHINE_IMAGE
  value: {{ .Values.gardener.machineImage }}
- name: APP_BROKER_KIM_CONFIG_MACHINE_IMAGE_VERSION
  value: {{ .Values.gardener.machineImageVersion }}
- name: APP_BROKER_KIM_CONFIG_MULTI_ZONE_CLUSTER
  value: "{{ .Values.gardener.multiZoneCluster }}"
- name: APP_BROKER_KIM_CONFIG_CONTROL_PLANE_FAILURE_TOLERANCE
  value: "{{ .Values.gardener.controlPlaneFailureTolerance }}"

- name: APP_BROKER_TIMEOUTS_PROVISIONING
  value: "{{ .Values.timeouts.provisioning }}"
- name: APP_BROKER_TIMEOUTS_DEPROVISIONING
  value: "{{ .Values.timeouts.deprovisioning }}"
- name: APP_BROKER_TIMEOUTS_GARDENER_CLUSTER_STEP
  value: "{{ .Values.timeouts.gardenerClusterStep }}"
- name: APP_BROKER_TIMEOUTS_RUNTIME_RESOURCE_STEP
  value: "{{ .Values.timeouts.runtimeResourceStep }}"
- name: APP_BROKER_TIMEOUTS_CLUSTER_UPDATE_STEP
  value: "{{ .Values.timeouts.clusterUpdateStep }}"
- name: APP_BROKER_TIMEOUTS_CHECK_RUNTIME_RESOURCE_DELETION_STEP
  value: "{{ .Values.timeouts.checkRuntimeResourceDeletionStep }}"
- name: APP_BROKER_TIMEOUTS_KYMA_RESOURCE_DELETION
  value: "{{ .Values.timeouts.kymaResourceDeletion }}"

Go structs:

type KimConfig struct {
	DefaultGardenerShootPurpose  string            `envconfig:"default=development"`
	DefaultTrialProvider         pkg.CloudProvider `envconfig:"default=AWS"`
	KubernetesVersion            string            `envconfig:"default=1.30"`
	MachineImage                 string            `envconfig:"optional"`
	MachineImageVersion          string            `envconfig:"optional"`
	MultiZoneCluster             bool              `envconfig:"default=false"`
	ControlPlaneFailureTolerance string            `envconfig:"optional"`
}

type Timeouts struct {
	Provisioning                     time.Duration `envconfig:"default=6h"`
	Deprovisioning                   time.Duration `envconfig:"default=5h"`
	GardenerClusterStep              time.Duration `envconfig:"default=3m"`
	RuntimeResourceStep              time.Duration `envconfig:"default=60m"`
	ClusterUpdateStep                time.Duration `envconfig:"default=2h"`
	CheckRuntimeResourceDeletionStep time.Duration `envconfig:"default=2h"`
	KymaResourceDeletion             time.Duration `envconfig:"default=30s"`
}

@KsaweryZietara KsaweryZietara removed their assignment Dec 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

No branches or pull requests

3 participants