Documentation ¶
Index ¶
- type ContainerID
- type DatapointCache
- func (dc *DatapointCache) AllDatapoints() []*datapoint.Datapoint
- func (dc *DatapointCache) AllDimProperties() []*atypes.DimProperties
- func (dc *DatapointCache) DeleteByKey(key interface{})
- func (dc *DatapointCache) HandleAdd(newObj runtime.Object) interface{}
- func (dc *DatapointCache) HandleDelete(oldObj runtime.Object) interface{}
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DatapointCache ¶
DatapointCache holds an up to date copy of datapoints pertaining to the cluster. It is updated whenever the HandleAdd method is called with new K8s resources.
func NewDatapointCache ¶
func NewDatapointCache(useNodeName bool, nodeConditionTypesToReport []string) *DatapointCache
NewDatapointCache creates a new clean cache
func (*DatapointCache) AllDatapoints ¶
func (dc *DatapointCache) AllDatapoints() []*datapoint.Datapoint
AllDatapoints returns all of the cached datapoints.
func (*DatapointCache) AllDimProperties ¶
func (dc *DatapointCache) AllDimProperties() []*atypes.DimProperties
AllDimProperties returns any dimension properties pertaining to the cluster
func (*DatapointCache) DeleteByKey ¶
func (dc *DatapointCache) DeleteByKey(key interface{})
DeleteByKey delete a cache entry by key. The supplied interface MUST be the same type returned by Handle[Add|Delete]. MUST HOLD LOCK!
func (*DatapointCache) HandleAdd ¶
func (dc *DatapointCache) HandleAdd(newObj runtime.Object) interface{}
HandleAdd accepts a new (or updated) object and updates the datapoint/prop cache as needed. MUST HOLD LOCK!!
func (*DatapointCache) HandleDelete ¶
func (dc *DatapointCache) HandleDelete(oldObj runtime.Object) interface{}
HandleDelete accepts an object that has been deleted and removes the associated datapoints/props from the cache. MUST HOLD LOCK!!