metrics

package
v1.8.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 2, 2025 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	AvgTotalDuration = "adv_cache_avg_duration_ns"
	AvgCacheDuration = "adv_cache_avg_cache_duration_ns"
	AvgProxyDuration = "adv_cache_avg_proxy_duration_ns"
	AvgErrorDuration = "adv_cache_avg_error_duration_ns"

	RPS                      = "adv_cache_rps"
	Total                    = "adv_cache_total"   // num of total requests
	Errored                  = "adv_cache_errors"  // num of errors
	Panicked                 = "adv_cache_panics"  // num of panics
	Proxied                  = "adv_cache_proxies" // num of proxy requests
	Hits                     = "adv_cache_cache_hits"
	Misses                   = "adv_cache_cache_misses"
	MapMemoryUsageMetricName = "adv_cache_cache_memory_usage"
	MapLength                = "adv_cache_cache_length"

	TotalSoftEvictions    = "adv_cache_soft_evicted_total_items"
	TotalSoftBytesEvicted = "adv_cache_soft_evicted_total_bytes"
	TotalSoftScans        = "adv_cache_soft_evicted_total_scans"

	TotalHardEvictions    = "adv_cache_hard_evicted_total_items"
	TotalHardBytesEvicted = "adv_cache_hard_evicted_total_bytes"

	TotalAdmAllowed    = "adv_cache_admission_allowed"
	TotalAdmNotAllowed = "adv_cache_admission_not_allowed"

	RefresherUpdated = "adv_cache_refresh_updated"
	RefresherErrors  = "adv_cache_refresh_errors"
	RefresherScans   = "adv_cache_refresh_scans"
	RefresherHits    = "adv_cache_refresh_hits"
	RefresherMiss    = "adv_cache_refresh_miss"

	BackendPolicy  = "adv_cache_backend_policy"
	LifetimePolicy = "adv_cache_lifetime_policy"

	IsBypassActive        = "adv_cache_is_bypass_active"
	IsCompressionActive   = "adv_cache_is_compression_active"
	IsObservabilityActive = "adv_cache_is_observability_active"
	IsAdmissionActive     = "adv_cache_is_admission_active"
)

Functions

func AddErrors added in v1.6.0

func AddErrors(value uint64)

func AddHardEvictionStatCounters added in v1.6.0

func AddHardEvictionStatCounters(bytes, items, admAllowed, admNotAllowed int64)

func AddHits added in v1.6.0

func AddHits(value uint64)

func AddLifetimeStatCounters added in v1.7.0

func AddLifetimeStatCounters(updated, errors, scans, miss, hits int64)

func AddMisses added in v1.6.0

func AddMisses(value uint64)

func AddPanics added in v1.7.0

func AddPanics(value uint64)

func AddProxiedNum added in v1.6.0

func AddProxiedNum(value uint64)

func AddSoftEvictionStatCounters added in v1.6.0

func AddSoftEvictionStatCounters(bytes, items, scans int64)

func AddTotal added in v1.6.0

func AddTotal(value uint64)

func SetAvgResponseTime added in v1.6.0

func SetAvgResponseTime(totalDur, cacheDur, proxyDur, errDur float64)

func SetBackendPolicy added in v1.7.0

func SetBackendPolicy(p upstream.Policy)

func SetCacheLength added in v1.6.0

func SetCacheLength(count uint64)

func SetCacheMemory added in v1.6.0

func SetCacheMemory(bytes uint64)

func SetIsAdmissionActive added in v1.8.2

func SetIsAdmissionActive(isActive bool)

func SetIsBypassActive added in v1.7.0

func SetIsBypassActive(isCacheActive bool)

func SetIsCompressionActive added in v1.7.0

func SetIsCompressionActive(isActive bool)

func SetIsObservabilityActive added in v1.8.2

func SetIsObservabilityActive(isActive bool)

func SetLifetimePolicy added in v1.8.2

func SetLifetimePolicy(p Policy)

func SetRPS added in v1.6.0

func SetRPS(value float64)

Types

type Policy added in v1.8.2

type Policy string
const (
	Remove  Policy = "remove"
	Refresh Policy = "refresh"
)

func NewLifetimePolicy added in v1.8.2

func NewLifetimePolicy(isRemoveOnTTL bool) Policy

func (Policy) Uint64 added in v1.8.2

func (p Policy) Uint64() uint64

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL