Operator

object Operator
Companion
class
class Object
trait Matchable
class Any

Type members

Classlikes

trait Aspect[-R, +E, T]

Event processor aspect

Event processor aspect

trait EventProcessor[-R, +E, T]

Operator event processor

Operator event processor

This is the type to be implemented when writing operators using the zio-k8s-operator library.

Type Params
E

Operator-specific error type

R

Operator environment

T

Resource type

case class OperatorContext(resourceType: K8sResourceType, namespace: Option[K8sNamespace])

Static contextual information for the event processors, usable for implementing generic loggers/metrics etc.

Static contextual information for the event processors, usable for implementing generic loggers/metrics etc.

final class ProvideSomeLayer[R0 <: Has[_], R, E, T](self: Operator[R, E, T]) extends AnyVal

Value members

Concrete methods

def cluster[R, E, T](eventProcessor: EventProcessor[R, E, T])(buffer: Int)(implicit evidence$4: Tag[R], evidence$5: Tag[T], evidence$6: ResourceMetadata[T]): ZIO[Has[ClusterResource[T]], Nothing, Operator[R, E, T]]

Creates an operator for a cluster resource

Creates an operator for a cluster resource

Type Params
E

Operator-specific error type

R

Operator environment

T

Resource type

Value Params
buffer

Buffer size for the incoming events

eventProcessor

Event processor implementation

Returns

An operator that can be run with Operator.start

def namespaced[R, E, T](eventProcessor: EventProcessor[R, E, T])(namespace: Option[K8sNamespace], buffer: Int)(implicit evidence$1: Tag[R], evidence$2: Tag[T], evidence$3: ResourceMetadata[T]): ZIO[Has[NamespacedResource[T]], Nothing, Operator[R, E, T]]

Creates an operator for a namespaced resource

Creates an operator for a namespaced resource

Type Params
E

Operator-specific error type

R

Operator environment

T

Resource type

Value Params
buffer

Buffer size for the incoming events

eventProcessor

Event processor implementation

namespace

Namespace to run in. If None, it will watch resources from all namespaces.

Returns

An operator that can be run with Operator.start