mtadapter

package
v0.40.0 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2024 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewAdapter

func NewAdapter(ctx context.Context, processed adapter.EnvConfigAccessor, ceClient cloudevents.Client) adapter.Adapter

func NewController

func NewController(ctx context.Context, adapter adapter.Adapter) *controller.Impl

NewController initializes the controller and registers event handlers to enqueue events.

func NewEnvConfig

func NewEnvConfig() adapter.EnvConfigAccessor

Types

type Adapter

type Adapter struct {
	// contains filtered or unexported fields
}

func (*Adapter) Remove

func (a *Adapter) Remove(name, namespace string)

func (*Adapter) Start

func (a *Adapter) Start(ctx context.Context) error

func (*Adapter) Update

func (a *Adapter) Update(ctx context.Context, obj *v1beta1.KafkaSource) error

type AdapterConfig

type AdapterConfig struct {
	adapter.EnvConfig

	PodName     string `envconfig:"POD_NAME" required:"true"`
	MPSLimit    int    `envconfig:"VREPLICA_LIMITS_MPS" required:"true"`
	MemoryLimit string `envconfig:"VREPLICA_LIMITS_MEMORY" required:"true"`
}

type MTAdapter

type MTAdapter interface {
	// Update is called when the source is ready and when the specification and/or status has changed.
	Update(ctx context.Context, source *v1beta1.KafkaSource) error

	// Remove is called when the source has been deleted.
	Remove(name, namespace string)
}

MTAdapter is the interface the multi-tenant KafkaSource adapter must implement

type Reconciler

type Reconciler struct {
	// contains filtered or unexported fields
}

Reconciler updates the internal Adapter cache kafkaSources

func (*Reconciler) ReconcileKind

func (r *Reconciler) ReconcileKind(ctx context.Context, source *v1beta1.KafkaSource) reconciler.Event

Jump to

Keyboard shortcuts

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