Documentation ¶
Index ¶
- func ErrDataTypes(id component.ID, from, to component.DataType) error
- type BaseRouter
- type CreateLogsToLogsFunc
- type CreateLogsToMetricsFunc
- type CreateLogsToProfilesFunc
- type CreateLogsToTracesFunc
- type CreateMetricsToLogsFunc
- type CreateMetricsToMetricsFunc
- type CreateMetricsToProfilesFunc
- type CreateMetricsToTracesFunc
- type CreateProfilesToLogsFunc
- type CreateProfilesToMetricsFunc
- type CreateProfilesToProfilesFunc
- type CreateProfilesToTracesFunc
- type CreateTracesToLogsFunc
- type CreateTracesToMetricsFunc
- type CreateTracesToProfilesFunc
- type CreateTracesToTracesFunc
- type Factory
- type FactoryOption
- func WithLogsToLogs(createLogsToLogs CreateLogsToLogsFunc, sl component.StabilityLevel) FactoryOption
- func WithLogsToMetrics(createLogsToMetrics CreateLogsToMetricsFunc, sl component.StabilityLevel) FactoryOption
- func WithLogsToProfiles(createLogsToProfiles CreateLogsToProfilesFunc, sl component.StabilityLevel) FactoryOption
- func WithLogsToTraces(createLogsToTraces CreateLogsToTracesFunc, sl component.StabilityLevel) FactoryOption
- func WithMetricsToLogs(createMetricsToLogs CreateMetricsToLogsFunc, sl component.StabilityLevel) FactoryOption
- func WithMetricsToMetrics(createMetricsToMetrics CreateMetricsToMetricsFunc, sl component.StabilityLevel) FactoryOption
- func WithMetricsToProfiles(createMetricsToProfiles CreateMetricsToProfilesFunc, ...) FactoryOption
- func WithMetricsToTraces(createMetricsToTraces CreateMetricsToTracesFunc, sl component.StabilityLevel) FactoryOption
- func WithProfilesToLogs(createProfilesToLogs CreateProfilesToLogsFunc, sl component.StabilityLevel) FactoryOption
- func WithProfilesToMetrics(createProfilesToMetrics CreateProfilesToMetricsFunc, ...) FactoryOption
- func WithProfilesToProfiles(createProfilesToProfiles CreateProfilesToProfilesFunc, ...) FactoryOption
- func WithProfilesToTraces(createProfilesToTraces CreateProfilesToTracesFunc, sl component.StabilityLevel) FactoryOption
- func WithTracesToLogs(createTracesToLogs CreateTracesToLogsFunc, sl component.StabilityLevel) FactoryOption
- func WithTracesToMetrics(createTracesToMetrics CreateTracesToMetricsFunc, sl component.StabilityLevel) FactoryOption
- func WithTracesToProfiles(createTracesToProfiles CreateTracesToProfilesFunc, sl component.StabilityLevel) FactoryOption
- func WithTracesToTraces(createTracesToTraces CreateTracesToTracesFunc, sl component.StabilityLevel) FactoryOption
- type Logs
- type Metrics
- type Profiles
- type Settings
- type Traces
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BaseRouter ¶ added in v0.109.0
type BaseRouter[T any] struct { Consumers map[component.ID]T // contains filtered or unexported fields }
func NewBaseRouter ¶ added in v0.109.0
func NewBaseRouter[T any](fanout func([]T) T, cm map[component.ID]T) BaseRouter[T]
func (*BaseRouter[T]) Consumer ¶ added in v0.109.0
func (r *BaseRouter[T]) Consumer(pipelineIDs ...component.ID) (T, error)
func (*BaseRouter[T]) PipelineIDs ¶ added in v0.109.0
func (r *BaseRouter[T]) PipelineIDs() []component.ID
type CreateLogsToLogsFunc ¶
type CreateLogsToLogsFunc func(context.Context, Settings, component.Config, consumer.Logs) (Logs, error)
CreateLogsToLogsFunc is the equivalent of Factory.CreateLogsToLogs().
type CreateLogsToMetricsFunc ¶
type CreateLogsToMetricsFunc func(context.Context, Settings, component.Config, consumer.Metrics) (Logs, error)
CreateLogsToMetricsFunc is the equivalent of Factory.CreateLogsToMetrics().
type CreateLogsToProfilesFunc ¶ added in v0.107.0
type CreateLogsToProfilesFunc func(context.Context, Settings, component.Config, consumerprofiles.Profiles) (Logs, error)
CreateLogsToProfilesFunc is the equivalent of Factory.CreateLogsToProfiles().
func (CreateLogsToProfilesFunc) CreateLogsToProfiles ¶ added in v0.107.0
func (f CreateLogsToProfilesFunc) CreateLogsToProfiles( ctx context.Context, set Settings, cfg component.Config, nextConsumer consumerprofiles.Profiles, ) (Logs, error)
CreateLogsToProfiles implements Factory.CreateLogsToProfiles().
type CreateLogsToTracesFunc ¶
type CreateLogsToTracesFunc func(context.Context, Settings, component.Config, consumer.Traces) (Logs, error)
CreateLogsToTracesFunc is the equivalent of Factory.CreateLogsToTraces().
type CreateMetricsToLogsFunc ¶
type CreateMetricsToLogsFunc func(context.Context, Settings, component.Config, consumer.Logs) (Metrics, error)
CreateMetricsToLogsFunc is the equivalent of Factory.CreateMetricsToLogs().
type CreateMetricsToMetricsFunc ¶
type CreateMetricsToMetricsFunc func(context.Context, Settings, component.Config, consumer.Metrics) (Metrics, error)
CreateMetricsToMetricsFunc is the equivalent of Factory.CreateMetricsToTraces().
type CreateMetricsToProfilesFunc ¶ added in v0.107.0
type CreateMetricsToProfilesFunc func(context.Context, Settings, component.Config, consumerprofiles.Profiles) (Metrics, error)
CreateMetricsToProfilesFunc is the equivalent of Factory.CreateMetricsToProfiles().
func (CreateMetricsToProfilesFunc) CreateMetricsToProfiles ¶ added in v0.107.0
func (f CreateMetricsToProfilesFunc) CreateMetricsToProfiles( ctx context.Context, set Settings, cfg component.Config, nextConsumer consumerprofiles.Profiles, ) (Metrics, error)
CreateMetricsToProfiles implements Factory.CreateMetricsToProfiles().
type CreateMetricsToTracesFunc ¶
type CreateMetricsToTracesFunc func(context.Context, Settings, component.Config, consumer.Traces) (Metrics, error)
CreateMetricsToTracesFunc is the equivalent of Factory.CreateMetricsToTraces().
type CreateProfilesToLogsFunc ¶ added in v0.107.0
type CreateProfilesToLogsFunc func(context.Context, Settings, component.Config, consumer.Logs) (Profiles, error)
CreateProfilesToLogsFunc is the equivalent of Factory.CreateProfilesToLogs().
type CreateProfilesToMetricsFunc ¶ added in v0.107.0
type CreateProfilesToMetricsFunc func(context.Context, Settings, component.Config, consumer.Metrics) (Profiles, error)
CreateProfilesToMetricsFunc is the equivalent of Factory.CreateProfilesToMetrics().
func (CreateProfilesToMetricsFunc) CreateProfilesToMetrics ¶ added in v0.107.0
func (f CreateProfilesToMetricsFunc) CreateProfilesToMetrics( ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Metrics, ) (Profiles, error)
CreateProfilesToMetrics implements Factory.CreateProfilesToMetrics().
type CreateProfilesToProfilesFunc ¶ added in v0.107.0
type CreateProfilesToProfilesFunc func(context.Context, Settings, component.Config, consumerprofiles.Profiles) (Profiles, error)
CreateProfilesToProfilesFunc is the equivalent of Factory.CreateProfilesToProfiles().
func (CreateProfilesToProfilesFunc) CreateProfilesToProfiles ¶ added in v0.107.0
func (f CreateProfilesToProfilesFunc) CreateProfilesToProfiles( ctx context.Context, set Settings, cfg component.Config, nextConsumer consumerprofiles.Profiles, ) (Profiles, error)
CreateProfilesToProfiles implements Factory.CreateProfilesToProfiles().
type CreateProfilesToTracesFunc ¶ added in v0.107.0
type CreateProfilesToTracesFunc func(context.Context, Settings, component.Config, consumer.Traces) (Profiles, error)
CreateProfilesToTracesFunc is the equivalent of Factory.CreateProfilesToTraces().
func (CreateProfilesToTracesFunc) CreateProfilesToTraces ¶ added in v0.107.0
func (f CreateProfilesToTracesFunc) CreateProfilesToTraces( ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Traces, ) (Profiles, error)
CreateProfilesToTraces implements Factory.CreateProfilesToTraces().
type CreateTracesToLogsFunc ¶
type CreateTracesToLogsFunc func(context.Context, Settings, component.Config, consumer.Logs) (Traces, error)
CreateTracesToLogsFunc is the equivalent of Factory.CreateTracesToLogs().
type CreateTracesToMetricsFunc ¶
type CreateTracesToMetricsFunc func(context.Context, Settings, component.Config, consumer.Metrics) (Traces, error)
CreateTracesToMetricsFunc is the equivalent of Factory.CreateTracesToMetrics().
type CreateTracesToProfilesFunc ¶ added in v0.107.0
type CreateTracesToProfilesFunc func(context.Context, Settings, component.Config, consumerprofiles.Profiles) (Traces, error)
CreateTracesToProfilesFunc is the equivalent of Factory.CreateTracesToProfiles().
func (CreateTracesToProfilesFunc) CreateTracesToProfiles ¶ added in v0.107.0
func (f CreateTracesToProfilesFunc) CreateTracesToProfiles( ctx context.Context, set Settings, cfg component.Config, nextConsumer consumerprofiles.Profiles, ) (Traces, error)
CreateTracesToProfiles implements Factory.CreateTracesToProfiles().
type CreateTracesToTracesFunc ¶
type CreateTracesToTracesFunc func(context.Context, Settings, component.Config, consumer.Traces) (Traces, error)
CreateTracesToTracesFunc is the equivalent of Factory.CreateTracesToTraces().
type Factory ¶
type Factory interface { component.Factory // CreateDefaultConfig creates the default configuration for the Connector. // This method can be called multiple times depending on the pipeline // configuration and should not cause side-effects that prevent the creation // of multiple instances of the Connector. // The object returned by this method needs to pass the checks implemented by // 'configtest.CheckConfigStruct'. It is recommended to have these checks in the // tests of any implementation of the Factory interface. CreateDefaultConfig() component.Config CreateTracesToTraces(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Traces) (Traces, error) CreateTracesToMetrics(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Metrics) (Traces, error) CreateTracesToLogs(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Logs) (Traces, error) CreateTracesToProfiles(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumerprofiles.Profiles) (Traces, error) CreateMetricsToTraces(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Traces) (Metrics, error) CreateMetricsToMetrics(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Metrics) (Metrics, error) CreateMetricsToLogs(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Logs) (Metrics, error) CreateMetricsToProfiles(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumerprofiles.Profiles) (Metrics, error) CreateLogsToTraces(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Traces) (Logs, error) CreateLogsToMetrics(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Metrics) (Logs, error) CreateLogsToLogs(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Logs) (Logs, error) CreateLogsToProfiles(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumerprofiles.Profiles) (Logs, error) CreateProfilesToProfiles(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumerprofiles.Profiles) (Profiles, error) CreateProfilesToTraces(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Traces) (Profiles, error) CreateProfilesToMetrics(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Metrics) (Profiles, error) CreateProfilesToLogs(ctx context.Context, set Settings, cfg component.Config, nextConsumer consumer.Logs) (Profiles, error) TracesToTracesStability() component.StabilityLevel TracesToMetricsStability() component.StabilityLevel TracesToLogsStability() component.StabilityLevel TracesToProfilesStability() component.StabilityLevel MetricsToTracesStability() component.StabilityLevel MetricsToMetricsStability() component.StabilityLevel MetricsToLogsStability() component.StabilityLevel MetricsToProfilesStability() component.StabilityLevel LogsToTracesStability() component.StabilityLevel LogsToMetricsStability() component.StabilityLevel LogsToLogsStability() component.StabilityLevel LogsToProfilesStability() component.StabilityLevel ProfilesToProfilesStability() component.StabilityLevel ProfilesToTracesStability() component.StabilityLevel ProfilesToMetricsStability() component.StabilityLevel ProfilesToLogsStability() component.StabilityLevel // contains filtered or unexported methods }
Factory is a factory interface for connectors.
This interface cannot be directly implemented. Implementations must use the NewFactory to implement it.
func NewFactory ¶
func NewFactory(cfgType component.Type, createDefaultConfig component.CreateDefaultConfigFunc, options ...FactoryOption) Factory
NewFactory returns a Factory.
type FactoryOption ¶
type FactoryOption interface {
// contains filtered or unexported methods
}
FactoryOption applies changes to Factory.
func WithLogsToLogs ¶
func WithLogsToLogs(createLogsToLogs CreateLogsToLogsFunc, sl component.StabilityLevel) FactoryOption
WithLogsToLogs overrides the default "error not supported" implementation for WithLogsToLogs and the default "undefined" stability level.
func WithLogsToMetrics ¶
func WithLogsToMetrics(createLogsToMetrics CreateLogsToMetricsFunc, sl component.StabilityLevel) FactoryOption
WithLogsToMetrics overrides the default "error not supported" implementation for WithLogsToMetrics and the default "undefined" stability level.
func WithLogsToProfiles ¶ added in v0.107.0
func WithLogsToProfiles(createLogsToProfiles CreateLogsToProfilesFunc, sl component.StabilityLevel) FactoryOption
WithLogsToProfiles overrides the default "error not supported" implementation for WithLogsToProfiles and the default "undefined" stability level.
func WithLogsToTraces ¶
func WithLogsToTraces(createLogsToTraces CreateLogsToTracesFunc, sl component.StabilityLevel) FactoryOption
WithLogsToTraces overrides the default "error not supported" implementation for WithLogsToTraces and the default "undefined" stability level.
func WithMetricsToLogs ¶
func WithMetricsToLogs(createMetricsToLogs CreateMetricsToLogsFunc, sl component.StabilityLevel) FactoryOption
WithMetricsToLogs overrides the default "error not supported" implementation for WithMetricsToLogs and the default "undefined" stability level.
func WithMetricsToMetrics ¶
func WithMetricsToMetrics(createMetricsToMetrics CreateMetricsToMetricsFunc, sl component.StabilityLevel) FactoryOption
WithMetricsToMetrics overrides the default "error not supported" implementation for WithMetricsToMetrics and the default "undefined" stability level.
func WithMetricsToProfiles ¶ added in v0.107.0
func WithMetricsToProfiles(createMetricsToProfiles CreateMetricsToProfilesFunc, sl component.StabilityLevel) FactoryOption
WithMetricsToProfiles overrides the default "error not supported" implementation for WithMetricsToProfiles and the default "undefined" stability level.
func WithMetricsToTraces ¶
func WithMetricsToTraces(createMetricsToTraces CreateMetricsToTracesFunc, sl component.StabilityLevel) FactoryOption
WithMetricsToTraces overrides the default "error not supported" implementation for WithMetricsToTraces and the default "undefined" stability level.
func WithProfilesToLogs ¶ added in v0.107.0
func WithProfilesToLogs(createProfilesToLogs CreateProfilesToLogsFunc, sl component.StabilityLevel) FactoryOption
WithProfilesToLogs overrides the default "error not supported" implementation for WithProfilesToLogs and the default "undefined" stability level.
func WithProfilesToMetrics ¶ added in v0.107.0
func WithProfilesToMetrics(createProfilesToMetrics CreateProfilesToMetricsFunc, sl component.StabilityLevel) FactoryOption
WithProfilesToMetrics overrides the default "error not supported" implementation for WithProfilesToMetrics and the default "undefined" stability level.
func WithProfilesToProfiles ¶ added in v0.107.0
func WithProfilesToProfiles(createProfilesToProfiles CreateProfilesToProfilesFunc, sl component.StabilityLevel) FactoryOption
WithProfilesToProfiles overrides the default "error not supported" implementation for WithProfilesToProfiles and the default "undefined" stability level.
func WithProfilesToTraces ¶ added in v0.107.0
func WithProfilesToTraces(createProfilesToTraces CreateProfilesToTracesFunc, sl component.StabilityLevel) FactoryOption
WithProfilesToTraces overrides the default "error not supported" implementation for WithProfilesToTraces and the default "undefined" stability level.
func WithTracesToLogs ¶
func WithTracesToLogs(createTracesToLogs CreateTracesToLogsFunc, sl component.StabilityLevel) FactoryOption
WithTracesToLogs overrides the default "error not supported" implementation for WithTracesToLogs and the default "undefined" stability level.
func WithTracesToMetrics ¶
func WithTracesToMetrics(createTracesToMetrics CreateTracesToMetricsFunc, sl component.StabilityLevel) FactoryOption
WithTracesToMetrics overrides the default "error not supported" implementation for WithTracesToMetrics and the default "undefined" stability level.
func WithTracesToProfiles ¶ added in v0.107.0
func WithTracesToProfiles(createTracesToProfiles CreateTracesToProfilesFunc, sl component.StabilityLevel) FactoryOption
WithTracesToProfiles overrides the default "error not supported" implementation for WithTracesToProfiles and the default "undefined" stability level.
func WithTracesToTraces ¶
func WithTracesToTraces(createTracesToTraces CreateTracesToTracesFunc, sl component.StabilityLevel) FactoryOption
WithTracesToTraces overrides the default "error not supported" implementation for WithTracesToTraces and the default "undefined" stability level.
type Logs ¶
A Logs connector acts as an exporter from a logs pipeline and a receiver to one or more traces, metrics, or logs pipelines. Logs feeds a consumer.Traces, consumer.Metrics, or consumer.Logs with data.
Examples:
- Structured logs containing span information could be consumed and emitted as traces.
- Metrics could be extracted from structured logs that contain numeric data.
- Logs could be collected in one pipeline and routed to another logs pipeline based on criteria such as attributes or other content of the log. The second pipeline can then process and export the log to the appropriate backend.
type Metrics ¶
A Metrics connector acts as an exporter from a metrics pipeline and a receiver to one or more traces, metrics, or logs pipelines. Metrics feeds a consumer.Traces, consumer.Metrics, or consumer.Logs with data.
Examples:
- Latency between related data points could be modeled and emitted as traces.
- Metrics could be collected in one pipeline and routed to another metrics pipeline based on criteria such as attributes or other content of the metric. The second pipeline can then process and export the metric to the appropriate backend.
- Metrics could be analyzed by a logs connector that emits events when particular criteria are met.
type Profiles ¶ added in v0.107.0
type Profiles interface { component.Component consumerprofiles.Profiles }
A Profiles connector acts as an exporter from a profiles pipeline and a receiver to one or more traces, metrics, logs, or profiles pipelines. Profiles feeds a consumer.Traces, consumer.Metrics, consumer.Logs, or consumerprofiles.Profiles with data.
Examples:
- Profiles could be collected in one pipeline and routed to another profiles pipeline based on criteria such as attributes or other content of the profile. The second pipeline can then process and export the profile to the appropriate backend.
- Profiles could be summarized by a metrics connector that emits statistics describing the number of profiles observed.
- Profiles could be analyzed by a logs connector that emits events when particular criteria are met.
type Settings ¶
type Settings struct { // ID returns the ID of the component that will be created. ID component.ID component.TelemetrySettings // BuildInfo can be used by components for informational purposes BuildInfo component.BuildInfo }
Settings configures Connector creators.
type Traces ¶
A Traces connector acts as an exporter from a traces pipeline and a receiver to one or more traces, metrics, or logs pipelines. Traces feeds a consumer.Traces, consumer.Metrics, or consumer.Logs with data.
Examples:
- Traces could be collected in one pipeline and routed to another traces pipeline based on criteria such as attributes or other content of the trace. The second pipeline can then process and export the trace to the appropriate backend.
- Traces could be summarized by a metrics connector that emits statistics describing the number of traces observed.
- Traces could be analyzed by a logs connector that emits events when particular criteria are met.