Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Recorder ¶
type Recorder interface { Event(reason, message string) Eventf(reason, messageFmt string, args ...interface{}) Warning(reason, message string) Warningf(reason, messageFmt string, args ...interface{}) // ForComponent allows to fiddle the component name before sending the event to sink. // Making more unique components will prevent the spam filter in upstream event sink from dropping // events. ForComponent(componentName string) Recorder // WithComponentSuffix is similar to ForComponent except it just suffix the current component name instead of overriding. WithComponentSuffix(componentNameSuffix string) Recorder // WithContext allows to set a context for event create API calls. WithContext(ctx context.Context) Recorder // ComponentName returns the current source component name for the event. // This allows to suffix the original component name with 'sub-component'. ComponentName() string Shutdown() }
Recorder is a simple event recording interface.
func NewRecorder ¶
func NewRecorder(client corev1client.EventInterface, sourceComponentName string, involvedObjectRef *corev1.ObjectReference) Recorder
NewRecorder returns new event recorder.
Click to show internal directories.
Click to hide internal directories.