mirror of
https://github.com/kubernetes-sigs/prometheus-adapter.git
synced 2026-04-06 09:47:54 +00:00
runMetrics earlier in the init process
This commit is contained in:
parent
cbba53e16b
commit
495c21091a
1 changed files with 2 additions and 2 deletions
|
|
@ -275,6 +275,8 @@ func main() {
|
|||
klog.Fatalf("unable to load metrics discovery config: %v", err)
|
||||
}
|
||||
|
||||
cmd.runMetrics()
|
||||
|
||||
// construct the provider
|
||||
cmProvider, err := cmd.makeProvider(promClient, wait.NeverStop)
|
||||
if err != nil {
|
||||
|
|
@ -302,8 +304,6 @@ func main() {
|
|||
klog.Fatalf("unable to install resource metrics API: %v", err)
|
||||
}
|
||||
|
||||
cmd.runMetrics()
|
||||
|
||||
// run the server
|
||||
if err := cmd.Run(wait.NeverStop); err != nil {
|
||||
klog.Fatalf("unable to run custom metrics adapter: %v", err)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue