Decouples Prometheus scrape cadence from upstream UniFi API calls so a 429 backoff loop on the controller side no longer stalls /metrics. The output plugin now owns a 60s background poller (configurable) whose result is served from an in-memory cache. Concurrent /scrape requests for the same target are coalesced via singleflight to prevent a noisy scraper from multiplying upstream load. Adds two new metrics so operators can detect cache staleness and refresh failures independently: - unpoller_prometheus_cache_age_seconds - unpoller_prometheus_refresh_failures_total Background goroutine recovers from panics so a malformed input payload no longer silently kills refreshes. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| MANUAL.md | ||
| README.md | ||
| k8s_influx.yaml | ||
| k8s_unifi_poller.yaml | ||
| remote_api_example.conf | ||
| remote_api_example.json | ||
| remote_api_example.yaml | ||
| up.conf.example | ||
| up.json.example | ||
| up.yaml.example | ||
README.md
Examples
This folder contains example configuration files in four
supported formats. You can use any format you want for
the config file, just give it the appropriate suffix for
the format. A JSON file should end with .json, and
YAML with .yaml. The default format is always TOML and
may have any other suffix.
Kubernetes
There are two files for Kubernetes deployment examples. Feel free to use them as you see fit. Please make sure to the delete all comments before deploying and make sure to fill in with correct values.
Notes
When adding new content to this folder, DO NOT MAKE NEW FOLDERS,
it will break make install on macOS (used for homebrew).