Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EventOptions ¶
type EventOptions struct { // EventType is the kubernetes event type (Normal or Warning). Defaults to Normal EventType string // EventReason is a Kubernetes EventReason of why this event is generated. // Reason should be short and unique; it should be in UpperCamelCase format (starting with a // capital letter). "reason" will be used to automate handling of events, so imagine people // writing switch statements to handle them. EventReason string }
type EventRecorder ¶
type EventRecorder interface { Eventf(object runtime.Object, opts EventOptions, messageFmt string, args ...interface{}) Warnf(object runtime.Object, opts EventOptions, messageFmt string, args ...interface{}) K8sRecorder() record.EventRecorder }
func NewEventRecorder ¶
func NewEventRecorder(kubeclientset kubernetes.Interface, rolloutEventCounter *prometheus.CounterVec) EventRecorder
type EventRecorderAdapter ¶
type EventRecorderAdapter struct { // Recorder is a K8s EventRecorder Recorder record.EventRecorder // RolloutEventCounter is a counter to increment on events RolloutEventCounter *prometheus.CounterVec // contains filtered or unexported fields }
EventRecorderAdapter implements the EventRecorder interface
func (*EventRecorderAdapter) Eventf ¶
func (e *EventRecorderAdapter) Eventf(object runtime.Object, opts EventOptions, messageFmt string, args ...interface{})
func (*EventRecorderAdapter) K8sRecorder ¶
func (e *EventRecorderAdapter) K8sRecorder() record.EventRecorder
func (*EventRecorderAdapter) Warnf ¶
func (e *EventRecorderAdapter) Warnf(object runtime.Object, opts EventOptions, messageFmt string, args ...interface{})
type FakeEventRecorder ¶
type FakeEventRecorder struct { EventRecorderAdapter Events []string }
FakeEventRecorder wraps EventRecorderAdapter but with a convenience function to get all the event reasons which were emitted
func NewFakeEventRecorder ¶
func NewFakeEventRecorder() *FakeEventRecorder
Click to show internal directories.
Click to hide internal directories.