Documentation ¶
Overview ¶
Package opentelemetry performs output operations for the opentelemetry extension
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { // ServiceName is the name of the service to use for the metrics // export, if not set it will use "k6" ServiceName null.String `json:"serviceName" envconfig:"K6_OTEL_SERVICE_NAME"` // ServiceVersion is the version of the service to use for the metrics // export, if not set it will use k6's library version ServiceVersion null.String `json:"serviceVersion" envconfig:"K6_OTEL_SERVICE_VERSION"` // MetricPrefix is the prefix to use for the metrics MetricPrefix null.String `json:"metricPrefix" envconfig:"K6_OTEL_METRIC_PREFIX"` // FlushInterval is the interval at which to flush metrics from the k6 FlushInterval types.NullDuration `json:"flushInterval" envconfig:"K6_OTEL_FLUSH_INTERVAL"` // ExporterType sets the type of OpenTelemetry Exporter to use ExporterType null.String `json:"exporterType" envconfig:"K6_OTEL_EXPORTER_TYPE"` // ExportInterval configures the intervening time between metrics exports ExportInterval types.NullDuration `json:"exportInterval" envconfig:"K6_OTEL_EXPORT_INTERVAL"` // Headers in W3C Correlation-Context format without additional semi-colon delimited metadata (i.e. "k1=v1,k2=v2") Headers null.String `json:"headers" envconfig:"K6_OTEL_HEADERS"` // TLSInsecureSkipVerify disables verification of the server's certificate chain TLSInsecureSkipVerify null.Bool `json:"tlsInsecureSkipVerify" envconfig:"K6_OTEL_TLS_INSECURE_SKIP_VERIFY"` // TLSCertificate is the path to the certificate file (rootCAs) to use for the exporter's TLS connection TLSCertificate null.String `json:"tlsCertificate" envconfig:"K6_OTEL_TLS_CERTIFICATE"` // TLSClientCertificate is the path to the certificate file (must be PEM encoded data) // to use for the exporter's TLS connection TLSClientCertificate null.String `json:"tlsClientCertificate" envconfig:"K6_OTEL_TLS_CLIENT_CERTIFICATE"` // TLSClientKey is the path to the private key file (must be PEM encoded data) to use for the exporter's TLS connection TLSClientKey null.String `json:"tlsClientKey" envconfig:"K6_OTEL_TLS_CLIENT_KEY"` // HTTPExporterInsecure disables client transport security for the Exporter's HTTP // connection. HTTPExporterInsecure null.Bool `json:"httpExporterInsecure" envconfig:"K6_OTEL_HTTP_EXPORTER_INSECURE"` // HTTPExporterEndpoint sets the target endpoint the OpenTelemetry Exporter // will connect to. HTTPExporterEndpoint null.String `json:"httpExporterEndpoint" envconfig:"K6_OTEL_HTTP_EXPORTER_ENDPOINT"` // HTTPExporterURLPath sets the target URL path the OpenTelemetry Exporter HTTPExporterURLPath null.String `json:"httpExporterURLPath" envconfig:"K6_OTEL_HTTP_EXPORTER_URL_PATH"` // GRPCExporterEndpoint sets the target endpoint the OpenTelemetry Exporter // will connect to. GRPCExporterEndpoint null.String `json:"grpcExporterEndpoint" envconfig:"K6_OTEL_GRPC_EXPORTER_ENDPOINT"` // GRPCExporterInsecure disables client transport security for the Exporter's gRPC // connection. GRPCExporterInsecure null.Bool `json:"grpcExporterInsecure" envconfig:"K6_OTEL_GRPC_EXPORTER_INSECURE"` }
Config represents the configuration for the OpenTelemetry output
func GetConsolidatedConfig ¶
GetConsolidatedConfig combines the options' values from the different sources and returns the merged options. The Order of precedence used is documented in the k6 Documentation https://grafana.com/docs/k6/latest/using-k6/k6-options/how-to/#order-of-precedence.
type Output ¶
type Output struct { output.SampleBuffer // contains filtered or unexported fields }
Output implements the lib.Output interface
func (*Output) Description ¶
Description returns a human-readable description of the output that will be shown in `k6 run`
func (*Output) StopWithTestError ¶
StopWithTestError flushes all remaining metrics and finalizes the test run
Source Files ¶
Click to show internal directories.
Click to hide internal directories.