Summary
TrackLog currently has no dedicated traceId field. For client errors, the traceId is buried inside the data JSON blob (at data.error.traceId, added by hoist-react's TraceService). For server-side trackService.track() calls, no traceId is captured at all.
With distributed tracing now in place, traceId should be a first-class field on TrackLog — similar to correlationId — so it can be queried, displayed in the Admin Console's Activity Tracking tab, and used for trace correlation across the observability stack.
Proposed Changes
- Add
traceId column to the TrackLog domain class and xh_track_log table.
- Capture
traceId from the active OTel span context in TrackService.prepareEntry() (server-side), and accept it as a submitted field from client track calls.
- Display
traceId in the Admin Console Activity Tracking viewer (hoist-react change).
- Include
traceId in TrackLog.formatForJSON() output.
🤖 Generated with Claude Code
Summary
TrackLog currently has no dedicated
traceIdfield. For client errors, the traceId is buried inside thedataJSON blob (atdata.error.traceId, added by hoist-react'sTraceService). For server-sidetrackService.track()calls, no traceId is captured at all.With distributed tracing now in place,
traceIdshould be a first-class field onTrackLog— similar tocorrelationId— so it can be queried, displayed in the Admin Console's Activity Tracking tab, and used for trace correlation across the observability stack.Proposed Changes
traceIdcolumn to theTrackLogdomain class andxh_track_logtable.traceIdfrom the active OTel span context inTrackService.prepareEntry()(server-side), and accept it as a submitted field from client track calls.traceIdin the Admin Console Activity Tracking viewer (hoist-react change).traceIdinTrackLog.formatForJSON()output.🤖 Generated with Claude Code