diff options
author | Dave Henderson <dhenderson@gmail.com> | 2020-12-30 13:44:02 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-30 11:44:02 -0700 |
commit | ebc278ec98bb24f2852b61fde2a9bf2e3d83818b (patch) | |
tree | afc2f604f9c59b64d3558eadd76330df4269efc7 /caddytest | |
parent | 79f3af99275447058951bc27fc45b669868dde7e (diff) |
metrics: allow disabling OpenMetrics negotiation (#3944)
* metrics: allow disabling OpenMetrics negotiation
Signed-off-by: Dave Henderson <dhenderson@gmail.com>
* fixup! metrics: allow disabling OpenMetrics negotiation
Diffstat (limited to 'caddytest')
-rw-r--r-- | caddytest/integration/caddyfile_adapt/metrics_disable_om.txt | 36 | ||||
-rw-r--r-- | caddytest/integration/caddyfile_adapt/metrics_syntax.txt | 33 |
2 files changed, 69 insertions, 0 deletions
diff --git a/caddytest/integration/caddyfile_adapt/metrics_disable_om.txt b/caddytest/integration/caddyfile_adapt/metrics_disable_om.txt new file mode 100644 index 0000000..2d7b24f --- /dev/null +++ b/caddytest/integration/caddyfile_adapt/metrics_disable_om.txt @@ -0,0 +1,36 @@ +:80 { + metrics /metrics { + disable_openmetrics + } +} +---------- +{ + "apps": { + "http": { + "servers": { + "srv0": { + "listen": [ + ":80" + ], + "routes": [ + { + "match": [ + { + "path": [ + "/metrics" + ] + } + ], + "handle": [ + { + "disable_openmetrics": true, + "handler": "metrics" + } + ] + } + ] + } + } + } + } +} diff --git a/caddytest/integration/caddyfile_adapt/metrics_syntax.txt b/caddytest/integration/caddyfile_adapt/metrics_syntax.txt new file mode 100644 index 0000000..ca08cea --- /dev/null +++ b/caddytest/integration/caddyfile_adapt/metrics_syntax.txt @@ -0,0 +1,33 @@ +:80 { + metrics /metrics +} +---------- +{ + "apps": { + "http": { + "servers": { + "srv0": { + "listen": [ + ":80" + ], + "routes": [ + { + "match": [ + { + "path": [ + "/metrics" + ] + } + ], + "handle": [ + { + "handler": "metrics" + } + ] + } + ] + } + } + } + } +} |