Open agilob opened 5 hours ago
Played with it a bit more and have to say this gives funny outcome:
K6_OTEL_EXPORTER_TYPE=http K6_OTEL_GRPC_EXPORTER_INSECURE=false \
K6_OTEL_GRPC_EXPORTER_ENDPOINT=prometheus:9090 \
K6_OTEL_HTTP_EXPORTER_URL_PATH=/api/v1/otlp/v1/metrics \
K6_OTEL_METRIC_PREFIX=agilob
output: opentelemetry (http, https://localhost:4318/api/v1/otlp/v1/metrics)
Setting insecure exporter overrides exporter URL and protocol?
Yup, works as documented below: changes my protocol and exporter to the default :D
K6_OTEL_GRPC_EXPORTER_ENDPOINT Configures the gRPC exporter endpoint. Default is localhost:4317.
Brief summary
Prometheus in version 2.54 has OTEL on http not GRPC, so to use it I'm using the following script command:
k6 version
v0.55.0
OS
linux
Docker version and image (if applicable)
No response
Steps to reproduce the problem
but the script fails because defining
K6_OTEL_EXPORTER_TYPE
overrides myK6_OTEL_GRPC_EXPORTER_ENDPOINT
:Expected behaviour
.
Actual behaviour
But when I remove
K6_OTEL_EXPORTER_TYPE
, my exporter URL is correct, but obviously won't work:Now, the url is correct, but protocol isn't.
On top of it, If I add
https://
to the exporter URL, it starts producing #4060 :