Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIDispatcher ¶
type APIDispatcher struct {
// contains filtered or unexported fields
}
APIDispatcher implements the fwk.APIDispatcher interface and allows for queueing and dispatching API calls asynchronously.
func New ¶
func New(client clientset.Interface, parallelization int, apiCallRelevances fwk.APICallRelevances) *APIDispatcher
New returns a new APIDispatcher object.
func (*APIDispatcher) Add ¶
func (ad *APIDispatcher) Add(newAPICall fwk.APICall, opts fwk.APICallOptions) error
Add adds an API call to the dispatcher's queue. It returns an error if the call is not enqueued (e.g., if it's skipped). The caller should handle ErrCallSkipped if returned.
func (*APIDispatcher) Run ¶
func (ad *APIDispatcher) Run(logger klog.Logger)
Run starts the main processing loop of the APIDispatcher, which pops calls from the queue and dispatches them to worker goroutines for execution.
func (*APIDispatcher) SyncObject ¶
SyncObject performs a two-way synchronization between the given object and a pending API call held within the dispatcher and returns the modified object.