weixin_39883129 2020-11-29 16:52
浏览 0

API Server Metrics collector

Description of change

Refactoring of the APIServer metrics to include the following:

  1. PingFailures by model UUID
  2. LogWriteCount by model UUID - including success/failures
  3. LogReadCount by model UUID - including success/disconnects/errors

The re-work also changes how we register the APIServer metrics with the prometheus registry, and offloads that work to the worker. This should remove the Unregister/Register dependency and fallback to the normal Register/Unregister strategy.

One word of caution is that we might end up with a very slow /metrics endpoint depending on how many model UUIDs we're dealing with.

Additionally I've also deprecated a few metrics because either they're not required, or they're using the wrong namespace/subsystem and they can be removed for 2.6 release.

QA steps

Follow the steps in this discourse post all the way to and including "Adding Juju-specific metrics".

Then to view the "production" controller prometheus metrics, you can use the following command: Note: fill in the $PASSWORD for the user you created from the discourse post.


juju show-controller production --format=json | jq '.production.details."api-endpoints"[0]' | xargs -I % echo "https://%/introspection/metrics" | xargs curl -k -s -u user-prometheus:$PASSWORD | grep juju_apiserver_log_

该提问来源于开源项目:juju/juju

  • 写回答

6条回答 默认 最新

  • weixin_39883129 2020-11-29 16:52
    关注

    I'm unsure if I'm registering the metrics collector correctly, so feedback around that would be great.

    评论

报告相同问题?