...

Package utils

import "github.com/chaos-mesh/chaos-mesh/controllers/chaosimpl/utils"
Overview
Index

Overview ▾

Variables

var (
    ErrUnknownType   error = errors.New("unknown type")
    ErrUnknownAction error = errors.New("unknown action")

    ErrContainerNotFound error = errors.New("container not found")
)
var Module = fx.Provide(
    NewContainerRecordDecoder,
)

type ContainerRecordDecoder

type ContainerRecordDecoder struct {
    client.Client
    *chaosdaemon.ChaosDaemonClientBuilder
}

func NewContainerRecordDecoder

func NewContainerRecordDecoder(c client.Client, builder *chaosdaemon.ChaosDaemonClientBuilder) *ContainerRecordDecoder

func (*ContainerRecordDecoder) DecodeContainerRecord

func (d *ContainerRecordDecoder) DecodeContainerRecord(ctx context.Context, record *v1alpha1.Record, obj v1alpha1.InnerObject) (decoded DecodedContainerRecord, err error)

type DecodedContainerRecord

type DecodedContainerRecord struct {
    PbClient      chaosdaemonclient.ChaosDaemonClientInterface
    ContainerId   string
    ContainerName string
    Pod           *v1.Pod
}