Skip to main content
Version: v2.x

Export Traces to OpenTelemetry Compliant Receiver from Hasura Data Connectors


Hasura Data Connectors can export and link internal OpenTelemetry data with GraphQL Engine to visualize the full timeline of a GraphQL request.


At present, data connectors only support traces via OpenTelemetry.


You can easily configure OpenTelemetry for your data connectors using environment variables.

GraphQL Data Connector

The GraphQL Data Connector — which power sources like Athena, MariaDB, MySQL, Oracle, Redshift, and Snowflake — is built on top of Quarkus with an OpenTelemetry extension. Therefore, the configuration properties of the connector also follow that of the extension:

Environment VariableTypeDefaultDescription
QUARKUS_OTEL_EXPORTER_OTLP_ENDPOINT stringThe endpoint of the OpenTelemetry receiver
QUARKUS_OTEL_EXPORTER_OTLP_PROTOCOL enum (grpc, http/protobuf)grpcThe protocol used to exchange data between the client and the server
QUARKUS_OTEL_EXPORTER_OTLP_HEADERS stringKey-value pairs to be used as headers associated with requests. i.e.: key1=value1,key2=value2
QUARKUS_OTEL_RESOURCE_ATTRIBUTES stringSpecify resource attributes in the following format: key1=val1,key2=val2

See the complete list of configuration reference here.

Mongo Data Connector

The Mongo Data Connector powers MongoDB connections and, thus, has a different configuration:

Environment VariableTypeDefaultDescription
OTEL_EXPORTER_OTLP_TRACES_ENDPOINT stringhttp://localhost:4318The endpoint of the OpenTelemetry receiver
OTEL_EXPORTER_OTLP_TRACES_PROTOCOL enum (grpc, http/protobuf)http/protobufThe protocol used to exchange data between the client and the server
OTEL_SERVICE_NAME stringName of the service
OTEL_PROPAGATORS enum (b3, b3multi, tracecontext, baggage, none)tracecontextComma-separate list of propagator schemes to use