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

chore: Add deprecation notes to customStateCheck #1708

Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions api-version-compatibility-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,5 @@ operator.kyma-project.io_moduletemplates.yaml:
v1beta1:
- .spec.properties.target
- .spec.required[]|select(.=="target")
v1beta2:
- .spec.properties.customStateCheck.description
1 change: 1 addition & 0 deletions api/v1beta2/moduletemplate_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ type ModuleTemplateSpec struct {
// +kubebuilder:pruning:PreserveUnknownFields
Descriptor machineryruntime.RawExtension `json:"descriptor"`

// CustomStateCheck is deprecated.
CustomStateCheck []*CustomStateCheck `json:"customStateCheck,omitempty"`
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,7 @@ spec:
pattern: ^[a-z]+$
type: string
customStateCheck:
description: CustomStateCheck is deprecated.
items:
properties:
jsonPath:
Expand Down
2 changes: 2 additions & 0 deletions docs/technical-reference/api/moduleTemplate-cr.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ If not specified, the **namespace** of the resource mentioned in **.spec.data**

### **.spec.customStateCheck**

> **CAUTION:** This field is deprecated and will be removed in the future.
Copy link
Contributor

@mmitoraj mmitoraj Jul 26, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The deprecation date is missing.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
> **CAUTION:** This field is deprecated and will be removed in the future.
> **CAUTION:** This field is deprecated and will be removed on {DATE}.

Tomasz-Smelcerz-SAP marked this conversation as resolved.
Show resolved Hide resolved

The `.spec.customStateCheck` field in Kyma Lifecycle Manager is primarily designed for third-party modules. For non-Kyma modules, the `status.state` might not be present, which the Lifecycle Manager relies on to determine the module state. This field enables users to define custom fields in the module Custom Resource (CR) that can be mapped to valid states supported by Lifecycle Manager.

Imagine a scenario where a module's health is indicated by `status.health` in its CR. In such cases, users can employ the customStateCheck configuration to map the health states to Lifecycle Manager states.
Expand Down
Loading