openyurt icon indicating copy to clipboard operation
openyurt copied to clipboard

[feature request] Add related validation into yurtappset webhook

Open vie-serendipity opened this issue 11 months ago • 2 comments

What would you like to be added: It is necessary to add related validation about yurtappset. Like native kubernetes resources, add validation of yurtappset created by users into webhook.

Why is this needed: First, kubernetes do validation about native resources in the webhook. It is natural to extend this style. Second, it is complicated to handle problems caused by invalid resources which may be produced by users. Subsequently, related controllerrevision handling will be tricky. We have to check whether it is invalid. https://github.com/openyurtio/openyurt/blob/34b14ccadfe26b8956144d21ec62a79a3aef1760/pkg/yurtmanager/controller/yurtappset/yurtappset_controller.go#L465 Finally, It is also unreasonable that a user need to check conditions of status after creating an invalid resource instead of just failing to create it.

others /kind feature

vie-serendipity avatar Mar 06 '24 02:03 vie-serendipity

@vie-serendipity yes, I agree with you that yurtappset webhook should validate the deployment template instead of K8s native validation.

rambohe-ch avatar Mar 19 '24 11:03 rambohe-ch

/assign @vie-serendipity

vie-serendipity avatar Mar 19 '24 15:03 vie-serendipity

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jun 18 '24 03:06 stale[bot]