Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Addressable ¶
type Addressable struct {
// Addressable address.
Address *url.URL
// Resource key.
ResourceKey types.NamespacedName
}
Addressable contains addressable resource data for the prober.
type Cache ¶
type Cache interface {
// GetStatus retries the status associated with the given key.
GetStatus(key string) Status
// UpsertStatus add or updates the status associated with the given key.
// Once the given key expires the onExpired callback will be called passing the arg parameter.
UpsertStatus(key string, status Status, arg interface{}, onExpired ExpirationFunc)
}
Cache is a key-status store.
type EnqueueFunc ¶
type EnqueueFunc func(key types.NamespacedName)
EnqueueFunc enqueues the given provided resource key.
type ExpirationFunc ¶
type ExpirationFunc func(key string, arg interface{})
ExpirationFunc is a callback called once an entry in the cache is expired.
type Func ¶
type Func func(ctx context.Context, addressable Addressable, expected Status) Status
Func type is an adapter to allow the use of ordinary functions as Prober. If f is a function with the appropriate signature, Func(f) is a Prober that calls f.
type IPsLister ¶ added in v0.29.5
func IPsListerFromService ¶ added in v0.29.5
func IPsListerFromService(svc types.NamespacedName) IPsLister
type Prober ¶
type Prober interface {
// Probe probes the provided Addressable resource and returns its Status.
Probe(ctx context.Context, addressable Addressable, expected Status) Status
}
Prober probes an addressable resource.
Click to show internal directories.
Click to hide internal directories.