[Issue #7] Add event metadata support #33

Merged
HugoNijhuis merged 1 commits from issue-7-event-metadata-support into main 2026-01-09 17:14:39 +00:00

1 Commits

Author SHA1 Message Date
97ff1c3346 Add event metadata support for distributed tracing and auditing
All checks were successful
CI / build (pull_request) Successful in 15s
- Add Metadata field (map[string]string) to Event struct with omitempty
- Add helper methods for common metadata: SetCorrelationID/GetCorrelationID,
  SetCausationID/GetCausationID, SetUserID/GetUserID, SetTraceID/GetTraceID,
  SetSpanID/GetSpanID
- Add WithMetadataFrom helper for copying metadata between events
- Add metadata key constants for standard fields
- Add comprehensive unit tests for metadata serialization and helpers
- Add store tests verifying metadata persistence

Closes #7

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-09 17:53:05 +01:00