Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ProfilesTotal tracks the total number of NextDNSProfile resources ProfilesTotal = prometheus.NewGauge(prometheus.GaugeOpts{ Name: "nextdns_profiles_total", Help: "Total number of NextDNSProfile resources", }) // ProfilesSyncedTotal tracks successful profile syncs ProfilesSyncedTotal = prometheus.NewCounterVec(prometheus.CounterOpts{ Name: "nextdns_profiles_synced_total", Help: "Total number of successful profile syncs", }, []string{"profile", "namespace"}) // ProfilesSyncErrorsTotal tracks failed profile syncs ProfilesSyncErrorsTotal = prometheus.NewCounterVec(prometheus.CounterOpts{ Name: "nextdns_profiles_sync_errors_total", Help: "Total number of failed profile syncs", }, []string{"profile", "namespace", "reason"}) // APIRequestDuration tracks NextDNS API call latency APIRequestDuration = prometheus.NewHistogramVec(prometheus.HistogramOpts{ Name: "nextdns_api_request_duration_seconds", Help: "Duration of NextDNS API requests in seconds", Buckets: prometheus.DefBuckets, }, []string{"operation"}) // APIRequestsTotal tracks total NextDNS API calls APIRequestsTotal = prometheus.NewCounterVec(prometheus.CounterOpts{ Name: "nextdns_api_requests_total", Help: "Total number of NextDNS API requests", }, []string{"operation", "status"}) // AllowlistsTotal tracks the total number of NextDNSAllowlist resources AllowlistsTotal = prometheus.NewGauge(prometheus.GaugeOpts{ Name: "nextdns_allowlists_total", Help: "Total number of NextDNSAllowlist resources", }) // DenylistsTotal tracks the total number of NextDNSDenylist resources DenylistsTotal = prometheus.NewGauge(prometheus.GaugeOpts{ Name: "nextdns_denylists_total", Help: "Total number of NextDNSDenylist resources", }) // TLDListsTotal tracks the total number of NextDNSTLDList resources TLDListsTotal = prometheus.NewGauge(prometheus.GaugeOpts{ Name: "nextdns_tldlists_total", Help: "Total number of NextDNSTLDList resources", }) )
Functions ¶
func RecordAPIRequest ¶
RecordAPIRequest records an API request with its duration and status
func RecordProfileSync ¶
func RecordProfileSync(profile, namespace string)
RecordProfileSync records a successful profile sync
func RecordProfileSyncError ¶
func RecordProfileSyncError(profile, namespace, reason string)
RecordProfileSyncError records a failed profile sync
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.