Documentation ¶
Index ¶
- Constants
- func BuildTransformsFromMapSlice(inputName string, trans []impl.LogTransform) ([]impl.LogTransform, error)
- func CreateDefaultCleanUpTransforms(dest v1alpha1.ClusterLogDestination) []impl.LogTransform
- func CreateDefaultTransforms(dest v1alpha1.ClusterLogDestination) []impl.LogTransform
- func CreateMultiLineTransforms(multiLineType v1alpha1.MultiLineParserType) []impl.LogTransform
- func CreateTransformsFromFilter(filters []v1alpha1.LogFilter) (transforms []impl.LogTransform, err error)
- func NewElasticsearchDestination(name string, cspec v1alpha1.ClusterLogDestinationSpec) impl.LogDestination
- func NewFileLogSource(name string, spec v1alpha1.FileSpec) impl.LogSource
- func NewKubernetesLogSource(name string, spec v1alpha1.KubernetesPodsSpec, namespaced bool) impl.LogSource
- func NewLogstashDestination(name string, cspec v1alpha1.ClusterLogDestinationSpec) impl.LogDestination
- func NewLokiDestination(name string, cspec v1alpha1.ClusterLogDestinationSpec) impl.LogDestination
- type ClusterLoggingConfig
- type ClusterLoggingConfigSpec
- type CommonTLS
- type CommonTransform
- type DynamicTransform
- type ElasticsearchAuth
- type ElasticsearchBulk
- type ElasticsearchEncoding
- type LogConfigGenerator
- func (vcg *LogConfigGenerator) AppendLogPipeline(inputSource impl.LogSource, transforms []impl.LogTransform, ...)
- func (vcg *LogConfigGenerator) BuildTransformsFromMapSlice(inputName string, trans []impl.LogTransform) ([]impl.LogTransform, error)
- func (vcg *LogConfigGenerator) GenerateConfig() ([]byte, error)
- type LogstashEncoding
- type LogstashKeepalive
- type LogstashTLS
- type LokiEncoding
- type PodLoggingConfig
- type PodLoggingConfigSpec
Constants ¶
View Source
const ( DestElasticsearch = "Elasticsearch" DestLogstash = "Logstash" DestLoki = "Loki" )
View Source
const ( SourceKubernetesPods = "KubernetesPods" SourceFile = "File" )
Variables ¶
This section is empty.
Functions ¶
func BuildTransformsFromMapSlice ¶
func BuildTransformsFromMapSlice(inputName string, trans []impl.LogTransform) ([]impl.LogTransform, error)
func CreateDefaultCleanUpTransforms ¶
func CreateDefaultCleanUpTransforms(dest v1alpha1.ClusterLogDestination) []impl.LogTransform
func CreateDefaultTransforms ¶
func CreateDefaultTransforms(dest v1alpha1.ClusterLogDestination) []impl.LogTransform
CreateDefaultTransforms creates predefined transform instruction for every log source
func CreateMultiLineTransforms ¶ added in v1.32.0
func CreateMultiLineTransforms(multiLineType v1alpha1.MultiLineParserType) []impl.LogTransform
func CreateTransformsFromFilter ¶
func CreateTransformsFromFilter(filters []v1alpha1.LogFilter) (transforms []impl.LogTransform, err error)
func NewElasticsearchDestination ¶
func NewElasticsearchDestination(name string, cspec v1alpha1.ClusterLogDestinationSpec) impl.LogDestination
func NewKubernetesLogSource ¶
func NewLogstashDestination ¶
func NewLogstashDestination(name string, cspec v1alpha1.ClusterLogDestinationSpec) impl.LogDestination
func NewLokiDestination ¶
func NewLokiDestination(name string, cspec v1alpha1.ClusterLogDestinationSpec) impl.LogDestination
Types ¶
type ClusterLoggingConfig ¶
type ClusterLoggingConfig struct { metav1.TypeMeta `json:",inline"` // Standard object's metadata. // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata // +optional metav1.ObjectMeta `json:"metadata,omitempty"` // Spec defines the behavior of a cluster log source. Spec ClusterLoggingConfigSpec `json:"spec"` Status v1alpha1.ClusterLoggingConfigStatus `json:"status,omitempty"` }
type ClusterLoggingConfigSpec ¶
type ClusterLoggingConfigSpec struct { // Type of cluster log source: KubernetesPods, File Type string `json:"type,omitempty"` // KubernetesPods describes spec for kubernetes pod source KubernetesPods v1alpha1.KubernetesPodsSpec `json:"kubernetesPods,omitempty"` // File describes spec for file source File v1alpha1.FileSpec `json:"file,omitempty"` // Transforms set ordered array of transforms. Possible values you can find into crd Transforms []impl.LogTransform `json:"transforms"` // DestinationRefs slice of ClusterLogDestination names DestinationRefs []string `json:"destinationRefs,omitempty"` }
type CommonTransform ¶
type CommonTransform struct { Name string `json:"-"` Type string `json:"type"` Inputs []string `json:"inputs"` }
func (*CommonTransform) GetInputs ¶
func (cs *CommonTransform) GetInputs() []string
func (*CommonTransform) GetName ¶
func (cs *CommonTransform) GetName() string
func (*CommonTransform) SetInputs ¶
func (cs *CommonTransform) SetInputs(inp []string)
func (*CommonTransform) SetName ¶
func (cs *CommonTransform) SetName(name string)
type DynamicTransform ¶
type DynamicTransform struct { CommonTransform DynamicArgsMap map[string]interface{} `json:"-"` }
func (DynamicTransform) MarshalJSON ¶
func (t DynamicTransform) MarshalJSON() ([]byte, error)
func (DynamicTransform) UnmarshalYAML ¶
func (t DynamicTransform) UnmarshalYAML(unmarshal func(interface{}) error) error
type ElasticsearchAuth ¶
type ElasticsearchAuth struct { Password string `json:"password,omitempty"` Strategy string `json:"strategy,omitempty"` User string `json:"user,omitempty"` AwsAccessKey string `json:"access_key_id,omitempty"` AwsSecretKey string `json:"secret_access_key,omitempty"` AwsAssumeRole string `json:"assume_role,omitempty"` }
type ElasticsearchBulk ¶ added in v1.32.4
type ElasticsearchEncoding ¶
type LogConfigGenerator ¶
type LogConfigGenerator struct {
// contains filtered or unexported fields
}
func NewLogConfigGenerator ¶
func NewLogConfigGenerator() *LogConfigGenerator
func (*LogConfigGenerator) AppendLogPipeline ¶
func (vcg *LogConfigGenerator) AppendLogPipeline(inputSource impl.LogSource, transforms []impl.LogTransform, destinations []impl.LogDestination)
func (*LogConfigGenerator) BuildTransformsFromMapSlice ¶
func (vcg *LogConfigGenerator) BuildTransformsFromMapSlice(inputName string, trans []impl.LogTransform) ([]impl.LogTransform, error)
func (*LogConfigGenerator) GenerateConfig ¶
func (vcg *LogConfigGenerator) GenerateConfig() ([]byte, error)
type LogstashEncoding ¶
type LogstashKeepalive ¶ added in v1.32.0
type LogstashKeepalive struct {
TimeSecs int `json:"time_secs"`
}
type LogstashTLS ¶
type LokiEncoding ¶
type PodLoggingConfig ¶
type PodLoggingConfig struct { metav1.TypeMeta `json:",inline"` // Standard object's metadata. // More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata // +optional metav1.ObjectMeta `json:"metadata,omitempty"` // Spec defines the behavior of a namespaced log source. Spec PodLoggingConfigSpec `json:"spec"` // Most recently observed status of a namespaced log source. Status v1alpha1.PodLoggingConfigStatus `json:"status,omitempty"` }
PodLoggingConfig specify target for kubernetes pods logs collecting in specified namespace
type PodLoggingConfigSpec ¶
type PodLoggingConfigSpec struct { // LabelSelector filter pods by label LabelSelector metav1.LabelSelector `json:"labelSelector,omitempty"` // Transforms set ordered array of transforms. Possible values you can find into crd Transforms []impl.LogTransform `json:"transforms"` // ClusterDestinationRefs slice of ClusterLogDestination names ClusterDestinationRefs []string `json:"clusterDestinationRefs,omitempty"` }
Click to show internal directories.
Click to hide internal directories.