rruntime

package
v0.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 14, 2024 License: MPL-2.0 Imports: 20 Imported by: 0

Documentation

Overview

Package rruntime implements runtime for Controllers (which reconcile full set of inputs on each iteration).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Adapter

type Adapter struct {
	controllerstate.StateAdapter
	// contains filtered or unexported fields
}

Adapter connects common controller-runtime and rruntime controller.

func NewAdapter

func NewAdapter(
	ctrl controller.Controller,
	adapterOptions adapter.Options,
) (*Adapter, error)

NewAdapter creates a new Adapter for the Controller.

func (*Adapter) CleanupOutputs

func (adapter *Adapter) CleanupOutputs(ctx context.Context, outputs ...resource.Kind) error

CleanupOutputs destroys all output resources that were not tracked.

func (*Adapter) Create

func (adapter *Adapter) Create(ctx context.Context, r resource.Resource) error

Create augments StateAdapter Create with output tracking.

func (*Adapter) EventCh

func (adapter *Adapter) EventCh() <-chan controller.ReconcileEvent

EventCh implements controller.Runtime interface.

func (*Adapter) Modify

func (adapter *Adapter) Modify(ctx context.Context, emptyResource resource.Resource, updateFunc func(resource.Resource) error) error

Modify augments StateAdapter Modify with output tracking.

func (*Adapter) ModifyWithResult

func (adapter *Adapter) ModifyWithResult(ctx context.Context, emptyResource resource.Resource, updateFunc func(resource.Resource) error) (resource.Resource, error)

ModifyWithResult augments StateAdapter ModifyWithResult with output tracking.

func (*Adapter) QueueReconcile

func (adapter *Adapter) QueueReconcile()

QueueReconcile implements controller.Runtime interface.

func (*Adapter) ResetRestartBackoff

func (adapter *Adapter) ResetRestartBackoff()

ResetRestartBackoff implements controller.Runtime interface.

func (*Adapter) Run

func (adapter *Adapter) Run(ctx context.Context)

Run the controller loop via the adapter.

func (*Adapter) StartTrackingOutputs

func (adapter *Adapter) StartTrackingOutputs()

StartTrackingOutputs enables output tracking for the controller.

func (*Adapter) Update

func (adapter *Adapter) Update(ctx context.Context, newResource resource.Resource) error

Update augments StateAdapter Update with output tracking.

func (*Adapter) UpdateInputs

func (adapter *Adapter) UpdateInputs(deps []controller.Input) error

UpdateInputs implements controller.Runtime interface.

func (*Adapter) WatchTrigger

func (adapter *Adapter) WatchTrigger(md *reduced.Metadata)

WatchTrigger is called by common controller runtime when there is a change in the watched resources.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL