What I am trying ot achieve:
I am trying to send traces to grafana cloud tempo using http.
Show some code:
this code is using, but it is using GRPC:
@Bean
public SpanExporter primaryOtlpGrpcSpanExporter() {
return OtlpGrpcSpanExporter.builder()
.setEndpoint("https://tempo-us-central1.grafana.net:443")
.addHeader("Authorization", "Basic ODEwNzcxOm[...]xOQ==")
.build();
}
I would like to use http instead of GRPC.
Hence, I used:
@Bean
public SpanExporter primaryOtlpGrpcSpanExporter() {
return OtlpHttpSpanExporter.builder()
.setEndpoint("https://tempo-us-central1.grafana.net:443/v1/traces")
.addHeader("Authorization", "Basic ODE[...]D0=")
.build();
}
Describe actual results:
With the Http exporter above, I am getting
2025-05-13T08:49:55.458+08:00 [question,,] WARN 16994 --- [httptry] [grafana.net/...] [ ] i.o.exporter.internal.http.HttpExporter : Failed to export spans. Server responded with HTTP status code 404. Error message: Unable to parse response body, HTTP status message:
Using this URL, I would get 405: https://tempo-us-central1.grafana.net:443
Describe expected result:
I would like to be able to send traces via Http protocol, and see the trace in Grafana cloud tempo.
Question:
What is the correct URL to send traces via http?