Categorygithub.com/fluxcd/pkg/cache
modulepackage
0.7.0
Repository: https://github.com/fluxcd/pkg.git
Documentation: pkg.go.dev

# Functions

MustMakeMetrics registers the metrics collectors in the given registerer.
New creates a new cache with the given configuration.
NewLRU creates a new LRU cache with the given capacity.
NewTokenCache returns a new TokenCache with the given capacity.
WithCleanupInterval sets the interval for the cache cleanup.
WithEventNamespaceLabel sets the namespace label for the cache events.
WithInvolvedObject sets the involved object for the cache metrics.
WithMaxDuration sets the maximum duration for the cache items.
WithMetricsPrefix sets the metrics prefix for the cache metrics.
WithMetricsRegisterer sets the Prometheus registerer for the cache metrics.

# Constants

CacheEventTypeHit is the event type for cache hits.
CacheEventTypeMiss is the event type for cache misses.
StatusFailure is the status for failed cache requests.
StatusSuccess is the status for successful cache requests.
TokenMaxDuration is the maximum duration that a token can have in the TokenCache.

# Variables

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Structs

Cache[T] is a thread-safe in-memory key/value store.
No description provided by the author
CacheErrorReason is a type that represents the reason for a cache error.
No description provided by the author
LRU is a thread-safe in-memory key/value store.
TokenCache is a thread-safe cache specialized in storing and retrieving access tokens.
TokenFlags contains the CLI flags that can be used to configure the TokenCache.

# Interfaces

Expirable is an interface for a cache store that supports expiration.
Store is an interface for a cache store.
Token is an interface that represents an access token that can be used to authenticate with a cloud provider.

# Type aliases

Options is a function that sets the store options.