You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trim span tags, metadata and log attribute values to backend 5000-char limit (#269)
The backend accepts at most 5000 characters per tag for spans and span
metadata. Add the limit as `AttributesSanitizer.Constraints.maxAttributeValueLength`
(the common sanitizer for all features) and enforce it across:
- Span tags: trim values via `AttributesSanitizer.sanitizeValues`, reused by
both `DDSpan` (`SpanSanitizer`) and `TestSpan`. Non-numeric values are
serialized to their `description` (the representation the encoders emit) and
truncated; numeric values pass through as metrics.
- Span metadata: trim keys and string values via `SpanMetadata.trimmed(toMaxLength:)`,
applied when the file header is built/updated in `SpansExporter`.
- Log attribute values: trim string values in `LogSanitizer`, referencing the
shared constant.
- `TestError` crash-log splitting now uses the shared constant instead of a
hardcoded 5000.
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
0 commit comments