iand675 / hs-opentelemetry

OpenTelemetry support for the Haskell programming language
https://iankduncan.com/projects/opentelemetry
BSD 3-Clause "New" or "Revised" License
76 stars 34 forks source link

Attribute max length calculation uses the wrong option value #113

Closed Profpatsch closed 3 weeks ago

Profpatsch commented 8 months ago

https://github.com/iand675/hs-opentelemetry/blob/02653bbfa286579be13cef17701da454ac3dfce1/api/src/OpenTelemetry/Attributes.hs#L92-L94

newAttrs should use attributeLengthLimit, otherwise attributes get cut at 128 bytes by default.

newAttrs = H.insert k (maybe id limitLengths attributeLengthLimit $ toAttribute v) attributes