OpenTelemetry

  • Endpoint: /otel
  • URL: https://${OBSERVE_CUSTOMER}.collect.observeinc.com/v1/otel
  • Maximum request size (compressed): 10MB
  • Maximum request size (uncompressed): 50MB
  • Individual metric, span, or event limit (including attributes and resource attributes): 1MB

Observe implements an OLTP HTTP endpoint at /v2/otel supporting the following observation types:

TypeURL Suffix *Protocol Status
Tracesv1/tracesstable
Metricsv1/metricsstable
Logsv1/logsstable
  • Suffix is for documentation purposes, Otel collecting agents will normally append this automatically for each type. So exporter would be configured for instance for customer id 123456: https://123456.collect.observeinc.com/v2/otel. The agent will automatically append the appropriate suffix for each observation type, resulting in complete endpoints such as https://123456.collect.observeinc.com/v2/otel/v1/logs for logs, https://123456.collect.observeinc.com/v2/otel/v1/metrics for metrics, or https://123456.collect.observeinc.com/v2/otel/v1/traces for traces.

Encode the request body in the Protobuf format and sent with the content-type application/x-protobuf. JSON encoding using application/json content-type is also supported. See Binary Protobuf Encoding in the OTLP specification.

This endpoint does not support GRPC.

Type-specific representations

Following tables illustrate for each Otel type how data is mapped from Otel Protobuf records into Observe source dataset entries.

Common

Common to all types is that we flatten the type-specific Resource and Scope hierarchies, turning any attributes on the resource level (opentelemetry.proto.resource.v1.Resource) into a dedicated resource_attributes field and scope information (opentelemetry.proto.common.v1.InstrumentationScope) into instrumentation_scope.

In addition to Otel specific fields Observe metadata is stored in a common meta column.

Otel FieldObserve Column / FieldComments
resource.attributesresource_attributesOtel kv list is represented as OPAL object
scope instrumentation_scopedata is flattened
metaObserve specific metadata (e.g. ingest token)

Logs

Below describes mapping of all the fields from LogRecord:

Otel FieldObserve Column / FieldComments
time_unix_nanotimestamp
observed_time_unix_nano timestampif time_unix_nano is empty
bodybodyBody is always stored as a string. Non-string values will be converted
attributesattributes
severity_numberfields.severity_number
severity_textfields.severity_text
trace_idfields.trace_id
span_idfields.span_id
dropped_attributes_countfields.dropped_attributes_countOnly stored if > 0
flagsfields.flagsOnly stored if > 0

Metrics

Below describes mapping of the fields from Metric or one of the nested classes, depending of the type of the metric:

Otel FieldObserve Column / FieldComments
time_unix_nanotimestamp
start_time_unix_nanofields.start_timeif present
namemetric
descriptiondescription
unitunit
data,aggregation_temporalitytypegauge -> gauge, sum + agg_temp_delta -> delta, sum + agg_temp_cumulative -> cumulativeCounter, histogram -> histogram, exponentialHistogram -> exponential_histogram, summary -> summary
value,quantile_valuesvaluefor gauge, sum and summary (see comments below for summary)
explicit_bounds,Buckets[]complex_valuefor histogram and exponential histogram, encapsulates all the bucket information. see below comments for min/max/count/sum handling
attributesattributes
aggregation_temporalityfields.aggregation_temporalityOnly for histograms, otherwise encoded in type
dropped_attributes_countfields.dropped_attributes_countOnly stored if > 0
flagsfields.flagsOnly stored if > 0

"Histogram" and "Exponential Histogram" metrics are represented into multiple "pseudo" metrics similar to Prometheus, with suffixes .sum, .count, .min and .max respectively. The types of .count and .sum will be corresponding to the aggregation temporality whereas .min and .max are always gauge. For .count the nunit will be null.

Similarly, "Summary" metrics are flattened into multiple "pseudo" timeseries, with a quantile attribute indicating the corresponding quantily. Given this and as they are deprecated we recommend to use histograms instead.

❗️

Warning

Histograms with cummulative aggregation are not currently supported! Data will be stored but quantile calculations will be wrong.

🚧

Caution

Exemplares are not currently supported and will be dropped.


Traces

Trace data is stored into 3 different datasets: Span, Span Event and Span Link. This is in order to normalize the data into a more relational form and allow easy access of span events as a standalone log dataset.

Span

Below describes mapping of all the fields from Span except for Event and Link types:

Otel FieldObserve Column / FieldComments
start_time_unix_nano start_time, durationduration=end_time-start_time
end_time_unix_nano end_time, durationduration=end_time-start_time
trace_idtrace_id
span_idspan_id
parent_span_idparent_span_id
namespan_name
kindspan_kindenum is resolved into string
attributesattributes
statusfield.statuscode enum is resolved into string
trace_statefields.trace_state
dropped_attributes_countfields.dropped_attributes_countOnly stored if > 0
dropped_events_countfields.dropped_events_countOnly stored if > 0
dropped_links_countfields.dropped_links_countOnly stored if > 0
flagsfields.flagsOnly stored if > 0

Span event

Below describes mapping of all the fields from Event plus fields inherited from the parent span:

Otel FieldObserve Column / FieldComments
time_unix_nanotimestamp
Span.trace_idtrace_idinherited from parent span
Span.span_idspan_idinherited from parent span
nameevent_name
attributesattributes
dropped_attributes_countfields.dropped_attributes_countOnly stored if > 0

Span link

Below describes mapping of all the fields from Link plus fields inherited from the parent span:

Otel FieldObserve Column / FieldComments
Span.start_time_unix_nano start_timeinherited from parent span
Span.end_time_unix_nano end_timeinherited from parent span
Span.trace_idtrace_idinherited from parent span
Span.span_idspan_idinherited from parent span
trace_idlinked_trace_idlinked trace_ _id
span_idlinked_span_idlinked span_id
attributesattributes
trace_statefields.trace_statetrace_state of linked trace
dropped_attributes_countfields.dropped_attributes_countOnly stored if > 0
flagsfields.flagsOnly stored if > 0