Skip to content

[SDTEST-3773] Add TelemetryLogExporter bridging OTel logs to TelemetryExporter#267

Merged
ypopovych merged 1 commit into
mainfrom
yehor.popovych/sdtest-3773-telemetry-log-exporter
Jun 1, 2026
Merged

[SDTEST-3773] Add TelemetryLogExporter bridging OTel logs to TelemetryExporter#267
ypopovych merged 1 commit into
mainfrom
yehor.popovych/sdtest-3773-telemetry-log-exporter

Conversation

@ypopovych

@ypopovych ypopovych commented Jun 1, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Adds TelemetryLogExporter (Sources/EventsExporter/Telemetry/TelemetryLogExporter.swift) implementing LogRecordExporter from OpenTelemetry SDK
  • Holds a TelemetryExporter as an injected property and forwards log batches to it as TelemetryLog.Logs
  • Maps ReadableLogRecordTelemetryLog: message from body/attributes/eventName, severity to ERROR/WARN/DEBUG level, exception.stacktrace attribute to stackTrace, remaining attributes as sorted "k:v" tags, timestamp as unix seconds

Also includes a refactor of LogEncoder (landed separately on main) that consolidates StaticCodingKeys + DynamicCodingKey into a single ExpressibleByStringLiteral CodingKeys struct, simplifying attribute encoding.

Test plan

  • Build passes clean for EventsExporter target (no errors or new warnings)
  • Verify TelemetryLogExporter wires up correctly when integrated into the main Exporter

Jira: SDTEST-3773

🤖 Generated with Claude Code

…yExporter

Implements LogRecordExporter that adapts ReadableLogRecord to TelemetryLog
and forwards batches to TelemetryExporter for storage and upload.

Co-Authored-By: Claude Sonnet 4.6 <[email protected]>
@ypopovych
ypopovych requested review from a team as code owners June 1, 2026 14:25
@ypopovych
ypopovych requested a review from anmarchenko June 1, 2026 14:38
@ypopovych
ypopovych merged commit 003d90c into main Jun 1, 2026
12 checks passed
@ypopovych
ypopovych deleted the yehor.popovych/sdtest-3773-telemetry-log-exporter branch June 1, 2026 14:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants