Documentation ¶
Index ¶
Constants ¶
View Source
const ( Normal = corev1.EventTypeNormal Warning = corev1.EventTypeWarning MonitorErrReason = "MonitorError" MonitorErrMsgFmt = "There was a problem monitoring for events in monitor '%s'" UncordonErrReason = "UncordonError" UncordonErrMsgFmt = "There was a problem while trying to uncordon the node: %s" UncordonReason = "Uncordon" UncordonMsg = "Node successfully uncordoned" PreDrainErrReason = "PreDrainError" PreDrainErrMsgFmt = "There was a problem executing the pre-drain task: %s" PreDrainReason = "PreDrain" PreDrainMsg = "Pre-drain task successfully executed" CordonErrReason = "CordonError" CordonErrMsgFmt = "There was a problem while trying to cordon the node: %s" CordonReason = "Cordon" CordonMsg = "Node successfully cordoned" CordonAndDrainErrReason = "CordonAndDrainError" CordonAndDrainErrMsgFmt = "There was a problem while trying to cordon and drain the node: %s" CordonAndDrainReason = "CordonAndDrain" CordonAndDrainMsg = "Node successfully cordoned and drained" PostDrainErrReason = "PostDrainError" PostDrainErrMsgFmt = "There was a problem executing the post-drain task: %s" PostDrainReason = "PostDrain" PostDrainMsg = "Post-drain task successfully executed" )
Kubernetes event types, reasons and messages
Variables ¶
View Source
var GetReasonForKind func(kind, monitor string) string = getReasonForKindV1
Functions ¶
func InitProbes ¶ added in v1.12.2
InitProbes will initialize, register and expose, via http server, the probes.
func SetReasonForKindVersion ¶ added in v1.18.0
Types ¶
type K8sEventRecorder ¶ added in v1.13.1
type K8sEventRecorder struct { record.EventRecorder // contains filtered or unexported fields }
K8sEventRecorder wraps a Kubernetes event recorder with some extra information
func InitK8sEventRecorder ¶ added in v1.13.1
func InitK8sEventRecorder(enabled bool, nodeName string, sqsMode bool, nodeMetadata ec2metadata.NodeMetadata, extraAnnotationsStr string, clientSet *kubernetes.Clientset) (K8sEventRecorder, error)
InitK8sEventRecorder creates a Kubernetes event recorder
func (K8sEventRecorder) Emit ¶ added in v1.13.1
func (r K8sEventRecorder) Emit(nodeName string, eventType, eventReason, eventMsgFmt string, eventMsgArgs ...interface{})
Emit a Kubernetes event for the given node and with the given event type, reason and message
type Metrics ¶
type Metrics struct {
// contains filtered or unexported fields
}
Metrics represents the stats for observability
func InitMetrics ¶
InitMetrics will initialize, register and expose, via http server, the metrics with Opentelemetry.
func (Metrics) ErrorEventsInc ¶
ErrorEventsInc will increment one for the event errors counter, partitioned by action, and only if metrics are enabled.
Click to show internal directories.
Click to hide internal directories.