Git Product home page Git Product logo

Comments (8)

MikeSpreitzer avatar MikeSpreitzer commented on June 11, 2024

/priority high

from kubestellar.

MikeSpreitzer avatar MikeSpreitzer commented on June 11, 2024

/remove-priority high
/priority medium

from kubestellar.

MikeSpreitzer avatar MikeSpreitzer commented on June 11, 2024

This is not entirely unrelated to #2094

from kubestellar.

MikeSpreitzer avatar MikeSpreitzer commented on June 11, 2024

Ugh. Of course controller-runtime does it differently. See https://book.kubebuilder.io/reference/metrics.html for some clues.

from kubestellar.

MikeSpreitzer avatar MikeSpreitzer commented on June 11, 2024

Also, OpenShift has an opinion about how to get metrics scraped (i.e., via the Prometheus Operator). https://book.kubebuilder.io/reference/metrics.html#exporting-metrics-for-prometheus talks about the provisions for that in controller-runtime. This is only an FYI, scraping is beyond the scope of this epic.

from kubestellar.

MikeSpreitzer avatar MikeSpreitzer commented on June 11, 2024

Regarding the OCM Status Add-On: although the framework (https://github.com/open-cluster-management-io/addon-framework/tree/v0.8.1) imports controller-runtime, that is only used in testing. The regular code does not use controller-runtime. Currently ks/OSA's controller and agent offer no metrics.

from kubestellar.

MikeSpreitzer avatar MikeSpreitzer commented on June 11, 2024

I ran the bash E2E test, using commit 5b6b18e, and scraped the metrics. I have attached the results.

kubestellar-controller-manager.metrics.txt

ocm-status-addon-agent.metrics.txt

ocm-status-addon-controller.metrics.txt

transport-controller.metrics.txt

The processes based on controller-runtime have an impoverished set of rest_client metrics.

The OCM Status Add-On Agent also lacks any workqueue metrics.

from kubestellar.

MikeSpreitzer avatar MikeSpreitzer commented on June 11, 2024

I think it is not going to be easy to change our controller-runtime based controllers to produce the normal client-go metrics that they currently do not. Witness the complaint and lack of response to https://kubernetes.slack.com/archives/C02MRBMN00Z/p1717604240073959 . Witness the exclusive registration of just one client-go metric at https://github.com/kubernetes-sigs/controller-runtime/blob/v0.18.3/pkg/metrics/client_go_adapter.go#L51-L54 , implying that controller-runtime has other ways of collecting the same or equivalent metrics, the absence of which I suppose is because our controllers are not using the relevant part(s) of controller-runtime.

To be clear, I am not saying that we can not add our own metrics; https://book.kubebuilder.io/reference/metrics.html#publishing-additional-metrics shows how to do that.

Since we plan to shift away from using controller-runtime, I am disinclined to pursue the missing client-go metrics unless and until I hear that some of those are specifically desired.

from kubestellar.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.