Skip to content

Conversation

@ryanzhang-oss
Copy link
Contributor

@ryanzhang-oss ryanzhang-oss commented Nov 24, 2024

Description of your changes

Fixes #

I have:

  • Run make reviewable to ensure this PR is ready for review.

How has this code been tested

Special notes for your reviewer

@ryanzhang-oss ryanzhang-oss changed the title api: Add delete override option feat: Add delete override option in the API Nov 24, 2024
// +kubebuilder:validation:Enum=JSONPatch;Delete
// +kubebuilder:default:JSONPatch
// +optional
OverrideType OverrideType `json:"overrideType,omitempty"`
Copy link
Contributor

Choose a reason for hiding this comment

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

Better to move this to be after ClusterSelector.

Why?

  • Specify the target and then specify the desired action upon the target.
  • OverrideType and JSONPatchOverrrides are used to describe the action. They should be together.

// +kubebuilder:validation:Enum=JSONPatch;Delete
// +kubebuilder:default:JSONPatch
// +optional
OverrideType OverrideType `json:"overrideType,omitempty"`
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
OverrideType OverrideType `json:"overrideType,omitempty"`
Type OverrideType `json:"type,omitempty"`

JSONPatchOverrides []JSONPatchOverride `json:"jsonPatchOverrides,omitempty"`
}

// OverrideType defines the type of Override
Copy link
Contributor

Choose a reason for hiding this comment

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

missing period

@ryanzhang-oss ryanzhang-oss merged commit 85a7531 into Azure:main Nov 27, 2024
12 checks passed
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

Successfully merging this pull request may close these issues.

3 participants