Documentation ¶
Index ¶
- type Builder
- type ObservabilityMgr
- func (o *ObservabilityMgr) BuildEPChain(ctx context.Context, entryPointName string, resourceName string) alice.Chain
- func (o *ObservabilityMgr) Close()
- func (o *ObservabilityMgr) MetricsRegistry() metrics.Registry
- func (o *ObservabilityMgr) RotateAccessLogs() error
- func (o *ObservabilityMgr) SemConvMetricsRegistry() *metrics.SemConvMetricsRegistry
- func (o *ObservabilityMgr) ShouldAddAccessLogs(resourceName string) bool
- func (o *ObservabilityMgr) ShouldAddMetrics(resourceName string) bool
- func (o *ObservabilityMgr) ShouldAddTracing(resourceName string) bool
- type PluginsBuilder
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Builder ¶
type Builder struct {
// contains filtered or unexported fields
}
Builder the middleware builder.
func NewBuilder ¶
func NewBuilder(configs map[string]*runtime.MiddlewareInfo, serviceBuilder serviceBuilder, pluginBuilder PluginsBuilder) *Builder
NewBuilder creates a new Builder.
type ObservabilityMgr ¶
type ObservabilityMgr struct {
// contains filtered or unexported fields
}
ObservabilityMgr is a manager for observability (AccessLogs, Metrics and Tracing) enablement.
func NewObservabilityMgr ¶
func NewObservabilityMgr(config static.Configuration, metricsRegistry metrics.Registry, semConvMetricRegistry *metrics.SemConvMetricsRegistry, accessLoggerMiddleware *accesslog.Handler, tracer *tracing.Tracer, tracerCloser io.Closer) *ObservabilityMgr
NewObservabilityMgr creates a new ObservabilityMgr.
func (*ObservabilityMgr) BuildEPChain ¶
func (o *ObservabilityMgr) BuildEPChain(ctx context.Context, entryPointName string, resourceName string) alice.Chain
BuildEPChain an observability middleware chain by entry point.
func (*ObservabilityMgr) Close ¶
func (o *ObservabilityMgr) Close()
Close closes the accessLogger and tracer.
func (*ObservabilityMgr) MetricsRegistry ¶
func (o *ObservabilityMgr) MetricsRegistry() metrics.Registry
MetricsRegistry is an accessor to the metrics registry.
func (*ObservabilityMgr) RotateAccessLogs ¶
func (o *ObservabilityMgr) RotateAccessLogs() error
func (*ObservabilityMgr) SemConvMetricsRegistry ¶
func (o *ObservabilityMgr) SemConvMetricsRegistry() *metrics.SemConvMetricsRegistry
SemConvMetricsRegistry is an accessor to the semantic conventions metrics registry.
func (*ObservabilityMgr) ShouldAddAccessLogs ¶
func (o *ObservabilityMgr) ShouldAddAccessLogs(resourceName string) bool
ShouldAddAccessLogs returns whether the access logs should be enabled for the given resource.
func (*ObservabilityMgr) ShouldAddMetrics ¶
func (o *ObservabilityMgr) ShouldAddMetrics(resourceName string) bool
ShouldAddMetrics returns whether the metrics should be enabled for the given resource.
func (*ObservabilityMgr) ShouldAddTracing ¶
func (o *ObservabilityMgr) ShouldAddTracing(resourceName string) bool
ShouldAddTracing returns whether the tracing should be enabled for the given resource.
type PluginsBuilder ¶
type PluginsBuilder interface {
Build(pName string, config map[string]interface{}, middlewareName string) (plugins.Constructor, error)
}
PluginsBuilder the plugin's builder interface.