kubernetes / kubernetes

Production-Grade Container Scheduling and Management
https://kubernetes.io
Apache License 2.0
107.2k stars 38.52k forks source link

admission/initializer: getting rid of constructor #124623

Closed sttts closed 2 weeks ago

sttts commented 2 weeks ago

What type of PR is this?

/kind cleanup

What this PR does / why we need it:

Remove pointless boilerplate.

// TODO: switch these parameters to use the builder pattern or just make them
//       all public, this construction method is pointless boilerplate.

Which issue(s) this PR fixes:

Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?

NONE

Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:

k8s-ci-robot commented 2 weeks ago

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: sttts Once this PR has been reviewed and has the lgtm label, please assign deads2k for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files: - ~~[pkg/kubeapiserver/OWNERS](https://github.com/kubernetes/kubernetes/blob/master/pkg/kubeapiserver/OWNERS)~~ [sttts] - **[plugin/pkg/admission/OWNERS](https://github.com/kubernetes/kubernetes/blob/master/plugin/pkg/admission/OWNERS)** Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
sttts commented 2 weeks ago

Agreed with @deads2k to go with constructors, also in generic controlplane follow-up.

cici37 commented 1 week ago

/triage accepted