f5 / otel-arrow-adapter

Adapter used to convert OTEL batches to/from OTEL Arrow batches in both directions.
Apache License 2.0
39 stars 6 forks source link

Better assert.Equiv and minor fixes #206

Closed lquerel closed 1 year ago

lquerel commented 1 year ago

Adjust assert.Equiv to recognize the OTel semantics:

The non-positional indices for resources (metrics, logs, and spans) are computed as a signature of the resource object itself. Attributes and map objects are organized in an order determined by their keys, followed by a JSON serialization. The non-positional index then corresponds to the MD5 hash of this serialization.

Similarly, non-positional indices for scopes are computed using the same method but applied to the scope object.

When a difference is observed, assert.Equiv returns:

In addition to the assert.Equiv improvements, the following changes have been integrated:

ToDo: