composer

package
v1.58.2 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Composer

type Composer struct {
	Source []v1alpha1.ClusterLoggingConfig
	Dest   []v1alpha1.ClusterLogDestination
}

func FromInput

func FromInput(input *go_hook.HookInput) *Composer

func (*Composer) Do

func (c *Composer) Do() ([]byte, error)

type Pipeline

type Pipeline struct {
	Source       PipelineSource
	Destinations []PipelineDestination
}

Pipeline is a representation of a single logical tube.

Example: ClusterLoggingConfig +(destinationRef) ClusterLogsDestination = Single Pipeline.

type PipelineDestination

type PipelineDestination struct {
	Inputs set.Set

	Destination apis.LogDestination
	Transforms  []apis.LogTransform
}

type PipelineSource

type PipelineSource struct {
	Source     apis.LogSource
	Transforms []apis.LogTransform
}

type VectorFile

type VectorFile struct {
	Sources    map[string]apis.LogSource      `json:"sources,omitempty"`
	Transforms map[string]apis.LogTransform   `json:"transforms,omitempty"`
	Sinks      map[string]apis.LogDestination `json:"sinks,omitempty"`
}

VectorFile is a vector config file corresponding golang structure.

func NewVectorFile

func NewVectorFile() *VectorFile

NewVectorFile inits a VectorFile instance.

func (*VectorFile) AppendLogPipeline

func (v *VectorFile) AppendLogPipeline(pipeline *Pipeline) error

AppendLogPipeline adds the pipeline to the accumulated ones. Pipeline always contains a single log source and one or more transform rules / sinks.

func (*VectorFile) ConvertToJSON

func (v *VectorFile) ConvertToJSON() ([]byte, error)

ConvertToJSON converts the vector file to the pretty-formatted JSON document.

Jump to

Keyboard shortcuts

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