Documentation ¶
Index ¶
- type CSVEventHandler
- func (h *CSVEventHandler) Create(evt event.CreateEvent, q workqueue.RateLimitingInterface)
- func (h *CSVEventHandler) Delete(evt event.DeleteEvent, q workqueue.RateLimitingInterface)
- func (h *CSVEventHandler) Free(addon *addonsv1alpha1.Addon)
- func (h *CSVEventHandler) Generic(evt event.GenericEvent, q workqueue.RateLimitingInterface)
- func (h *CSVEventHandler) ReplaceMap(addon *addonsv1alpha1.Addon, csvKeys ...client.ObjectKey) (changed bool)
- func (h *CSVEventHandler) Update(evt event.UpdateEvent, q workqueue.RateLimitingInterface)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CSVEventHandler ¶
type CSVEventHandler struct {
// contains filtered or unexported fields
}
CSV event handler mapping CSV events to registered watching Addons.
func NewCSVEventHandler ¶
func NewCSVEventHandler() *CSVEventHandler
func (*CSVEventHandler) Create ¶
func (h *CSVEventHandler) Create(evt event.CreateEvent, q workqueue.RateLimitingInterface)
Create is called in response to an create event.
func (*CSVEventHandler) Delete ¶
func (h *CSVEventHandler) Delete(evt event.DeleteEvent, q workqueue.RateLimitingInterface)
Delete is called in response to a delete event.
func (*CSVEventHandler) Free ¶
func (h *CSVEventHandler) Free(addon *addonsv1alpha1.Addon)
Free removes all event mappings associated with the given Addon.
func (*CSVEventHandler) Generic ¶
func (h *CSVEventHandler) Generic(evt event.GenericEvent, q workqueue.RateLimitingInterface)
Generic is called in response to an event of an unknown type or a synthetic event triggered as a cron or external trigger request - e.g. reconcile Autoscaling, or a Webhook.
func (*CSVEventHandler) ReplaceMap ¶
func (h *CSVEventHandler) ReplaceMap( addon *addonsv1alpha1.Addon, csvKeys ...client.ObjectKey, ) (changed bool)
ReplaceMap tells the event handler about a Addon > CSV relation and setup mapping of future events. It returns true when the existing mapping had to be changed. WARNING: This method is potentially racy when the Addon object is not reenqueued by the calling reconcile loop when the mapping changes, as incomming events might be dropped before this method completes and the event mapping is updated. Calling code needs to make sure to reenqueue the Addon object for _every_ mapping change or CSV events might not be processed.
func (*CSVEventHandler) Update ¶
func (h *CSVEventHandler) Update(evt event.UpdateEvent, q workqueue.RateLimitingInterface)
Update is called in response to an update event.