Documentation
¶
Index ¶
- Constants
- Variables
- func BackendFactory(bf proxy.BackendFactory) proxy.BackendFactory
- func HTTPRequestExecutor(clientFactory transport.HTTPClientFactory) transport.HTTPRequestExecutor
- func IsBackendEnabled() bool
- func IsPipeEnabled() bool
- func IsRouterEnabled() bool
- func Middleware(name string) proxy.Middleware
- func NewHTTPClient(ctx context.Context) *http.Client
- func ProxyFactory(pf proxy.Factory) proxy.FactoryFunc
- func Register(ctx context.Context, srvCfg config.ServiceConfig, vs ...*view.View) error
- func RegisterExporterFactories(ef ExporterFactory)
- type Config
- type EnabledLayers
- type ExporterFactory
- type InfluxDBConfig
- type JaegerConfig
- type OcagentConfig
- type PrometheusConfig
- type StackdriverConfig
- type XrayConfig
- type ZipkinConfig
Constants ¶
View Source
const ( ContextKey = "opencensus-request-span" Namespace = "github_com/devopsfaith/krakend-opencensus" )
Variables ¶
View Source
var ( DefaultViews = []*view.View{ ochttp.ClientSentBytesDistribution, ochttp.ClientReceivedBytesDistribution, ochttp.ClientRoundtripLatencyDistribution, ochttp.ClientCompletedCount, ochttp.ServerRequestCountView, ochttp.ServerRequestBytesView, ochttp.ServerResponseBytesView, ochttp.ServerLatencyView, ochttp.ServerRequestCountByMethod, ochttp.ServerResponseCountByStatusCode, } )
Functions ¶
func BackendFactory ¶
func BackendFactory(bf proxy.BackendFactory) proxy.BackendFactory
func HTTPRequestExecutor ¶
func HTTPRequestExecutor(clientFactory transport.HTTPClientFactory) transport.HTTPRequestExecutor
func IsBackendEnabled ¶
func IsBackendEnabled() bool
func IsPipeEnabled ¶
func IsPipeEnabled() bool
func IsRouterEnabled ¶
func IsRouterEnabled() bool
func Middleware ¶
func Middleware(name string) proxy.Middleware
func ProxyFactory ¶
func ProxyFactory(pf proxy.Factory) proxy.FactoryFunc
func RegisterExporterFactories ¶
func RegisterExporterFactories(ef ExporterFactory)
Types ¶
type Config ¶
type Config struct {
SampleRate int `json:"sample_rate"`
ReportingPeriod int `json:"reporting_period"`
EnabledLayers *EnabledLayers `json:"enabled_layers"`
Exporters struct {
InfluxDB *InfluxDBConfig `json:"influxdb"`
Zipkin *ZipkinConfig `json:"zipkin"`
Jaeger *JaegerConfig `json:"jaeger"`
Prometheus *PrometheusConfig `json:"prometheus"`
Logger *struct{} `json:"logger"`
Xray *XrayConfig `json:"xray"`
Stackdriver *StackdriverConfig `json:"stackdriver"`
Ocagent *OcagentConfig `json:"ocagent"`
} `json:"exporters"`
}
type EnabledLayers ¶
type InfluxDBConfig ¶
type JaegerConfig ¶
type OcagentConfig ¶
type PrometheusConfig ¶
type StackdriverConfig ¶
type XrayConfig ¶
Click to show internal directories.
Click to hide internal directories.