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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃悰 Reintroduce AddMetricsServerExtraHandler on manager #2813

Conversation

vincepri
Copy link
Member

@vincepri vincepri commented May 6, 2024

(Edited by @sbueringer)

Goal of this PR is to reintroduce a means of adding metrics server extra handlers to an existing manager, that was dropped in #2407.

This can be very useful with the "SetupWithManager" pattern, e.g. used in Cluster API (https://github.com/kubernetes-sigs/cluster-api/blob/e23c10dd627125b6d43edf74f059c9e170731446/internal/controllers/cluster/cluster_controller.go#L79). In SetupWithManager funcs the manager is available, but at this point it would be too late to modify the metrics options that have been used to create the manager.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label May 6, 2024
@k8s-ci-robot k8s-ci-robot added approved Indicates a PR has been approved by an approver from all required OWNERS files. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels May 6, 2024
@vincepri
Copy link
Member Author

vincepri commented May 6, 2024

/cherry-pick release-0.18
/cherry-pick release-0.17
/cherry-pick release-0.16

@k8s-infra-cherrypick-robot

@vincepri: once the present PR merges, I will cherry-pick it on top of release-0.18 in a new PR and assign it to you.

In response to this:

/cherry-pick release-0.18
/cherry-pick release-0.17
/cherry-pick release-0.16

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@vincepri
Copy link
Member Author

vincepri commented May 6, 2024

/cherry-pick release-0.17

@k8s-infra-cherrypick-robot

@vincepri: once the present PR merges, I will cherry-pick it on top of release-0.17 in a new PR and assign it to you.

In response to this:

/cherry-pick release-0.17

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@vincepri
Copy link
Member Author

vincepri commented May 6, 2024

/cherry-pick release-0.16

@k8s-infra-cherrypick-robot

@vincepri: once the present PR merges, I will cherry-pick it on top of release-0.16 in a new PR and assign it to you.

In response to this:

/cherry-pick release-0.16

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@vincepri vincepri force-pushed the reintroduce-add-extra-metrics-handler branch from b28ea95 to eece44b Compare May 6, 2024 16:49
@vincepri
Copy link
Member Author

vincepri commented May 6, 2024

/retest

1 similar comment
@vincepri
Copy link
Member Author

vincepri commented May 6, 2024

/retest

pkg/manager/internal.go Show resolved Hide resolved
pkg/manager/manager.go Outdated Show resolved Hide resolved
pkg/manager/manager.go Outdated Show resolved Hide resolved
pkg/metrics/server/server.go Outdated Show resolved Hide resolved
@vincepri vincepri force-pushed the reintroduce-add-extra-metrics-handler branch 3 times, most recently from 894cb35 to fac7120 Compare May 6, 2024 18:39
@vincepri vincepri changed the title 馃悰 Reintroduce AddMetricsExtraHandler on manager 馃悰 Reintroduce AddMetricsServerExtraHandler on manager May 6, 2024
Signed-off-by: Vince Prignano <vince@prigna.com>
@vincepri vincepri force-pushed the reintroduce-add-extra-metrics-handler branch from fac7120 to 610870e Compare May 6, 2024 18:58
@k8s-ci-robot
Copy link
Contributor

@vincepri: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
pull-controller-runtime-apidiff 610870e link false /test pull-controller-runtime-apidiff

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

@sbueringer
Copy link
Member

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label May 6, 2024
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: sbueringer, vincepri

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

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [sbueringer,vincepri]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 442d71f0ea57fd72a482084d5176ae0a1ea73a2e

@k8s-ci-robot k8s-ci-robot merged commit 0f76f20 into kubernetes-sigs:main May 6, 2024
8 of 9 checks passed
@k8s-infra-cherrypick-robot

@vincepri: new pull request created: #2815

In response to this:

/cherry-pick release-0.17

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-infra-cherrypick-robot

@vincepri: new pull request created: #2816

In response to this:

/cherry-pick release-0.16

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-infra-cherrypick-robot

@vincepri: new pull request created: #2817

In response to this:

/cherry-pick release-0.18
/cherry-pick release-0.17
/cherry-pick release-0.16

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants