Christian Schlotter
Christian Schlotter
I'd like to propose the following UX for the generator (kudo's to @sbueringer and @fabriziopandini which helped brainstorming and compiling this). We did take the metrics at [Cluster API](https://github.com/kubernetes-sigs/cluster-api/blob/main/hack/observability/kube-state-metrics/crd-config.yaml) and...
/remove-lifecycle stale
/remove-lifecycle stale
Happy to gather early feedback on this. The work is mostly based on what metrics got defined for Cluster API's resources.
Example usage: ```sh PATH_TO_CAPI_FORK=/some/path metric-gen \ "${PATH_TO_CAPI_FORK}/bootstrap/kubeadm/api/v1beta1" \ "${PATH_TO_CAPI_FORK}/controlplane/kubeadm/api/v1beta1" \ "${PATH_TO_CAPI_FORK}/api/v1beta1" \ "${PATH_TO_CAPI_FORK}/exp/api/v1beta1" \ > metrics.yaml ```
moving to draft after seeing that ci is happy for now
> Thanks @chrischdi for submitting this! Unfortunately it seems like every maintainer is quite busy, I hope to get a chance to review it next week and provide better feedback....
Also wondering if this should be implemented as kubebuilder plugin instead https://book.kubebuilder.io/plugins/plugins.html (which is pretty new) Note: does not match the use case if I got it right
Note: currently reviving this PR 🎉 Currently works for CAPI and CAPV: * CAPI branch with markers: https://github.com/chrischdi/cluster-api/tree/experiment-metrics-gen-flags * CAPV branch with markes: https://github.com/chrischdi/cluster-api-provider-vsphere/tree/pr-exp-metric-gen Result configuration: ```yaml spec: resources: -...
> This likely requires feedback from other maintainers: I wonder if it would simplify the release process by a lot if we were able to incorporate it in the kube-state-metrics...