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

Allow scrapping of OpenStack load-balancer-id #2428

Closed

Conversation

mandre
Copy link
Member

@mandre mandre commented Aug 2, 2024

This PR is made of two separate changes.

The first one remove kube_*_annotations from the deny list, as it is no longer needed since kubernetes/kube-state-metrics#2145 and prevents the collection of kube_*_annotations.

The second change effectively enables scrapping of OpenStack load-balancer-id.

  • I added CHANGELOG entry for this change.
  • No user facing changes, so no entry in CHANGELOG was needed.

Since kubernetes/kube-state-metrics#2145,
kube-state-metrics does not collect `kube_*_annotations` metrics by
default. It's no longer necessary to add them to the metrics' deny list.

Removing `kube_*_annotations` from the deny list allows us to enable
scrapping of annotation metrics via the `--metric-annotations-allowlist`
option.

Additionally, we were missing a comma, which might have been a problem
in the comma-separated list of arguments.
Copy link
Contributor

openshift-ci bot commented Aug 2, 2024

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: mandre
Once this PR has been reviewed and has the lgtm label, please assign machine424 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:

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

In order to enable correlated metrics between OpenShift and the
underlying platform, we need a way to map resources. We already have it
for instances and volumes via the `kube_node_info` and
`kube_persistentvolume_info` respectively, however we don't have the
load-balancer ID in `kube_service_info`.

For OpenStack, this mapping lives in the
`loadbalancer.openstack.org/load-balancer-id` annotation in the service
object.

This patches enables scrapping OpenStack load-balancer-id, which can be
found in the metric `kube_service_annotations`, label
`annotation_loadbalancer_openstack_org_load_balancer_id`.
@mandre mandre force-pushed the openstack-service-annotations branch from 116e957 to 284b1bb Compare August 2, 2024 07:17
@jan--f
Copy link
Contributor

jan--f commented Aug 2, 2024

/cc @rexagod

@openshift-ci openshift-ci bot requested a review from rexagod August 2, 2024 08:37
@jan--f
Copy link
Contributor

jan--f commented Aug 2, 2024

I'm generally in favor of this, though I think we have yet another setting to gatekeep that should really be user accessible, similar to https://issues.redhat.com/browse/MON-2809.

Iiuc we also no longer need to deny kube_secret_labels?

@mandre
Copy link
Member Author

mandre commented Aug 2, 2024

I'm generally in favor of this, though I think we have yet another setting to gatekeep that should really be user accessible, similar to https://issues.redhat.com/browse/MON-2809.

Iiuc we also no longer need to deny kube_secret_labels?

Yep, that's also my understanding I can do that in a separate PR if you'd like.

Copy link
Contributor

openshift-ci bot commented Aug 2, 2024

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

Test name Commit Details Required Rerun command
ci/prow/e2e-agnostic-operator 284b1bb link true /test e2e-agnostic-operator
ci/prow/versions 284b1bb link false /test versions
ci/prow/e2e-aws-ovn-techpreview 284b1bb link true /test e2e-aws-ovn-techpreview

Full PR test history. Your PR dashboard.

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.

@mandre
Copy link
Member Author

mandre commented Aug 2, 2024

Closing in favor of #2430. We want to use a more dynamic approach for collecting the needed annotation thanks to CRS.
/close

@openshift-ci openshift-ci bot closed this Aug 2, 2024
Copy link
Contributor

openshift-ci bot commented Aug 2, 2024

@mandre: Closed this PR.

In response to this:

Closing in favor of #2430. We want to use a more dynamic approach for collecting the needed annotation thanks to CRS.
/close

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
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants