namespace GB5Shared.Telemetry.Observability; /// /// Immutable snapshot of a single request or background operation captured by /// and written to TOBSERVABILITY. /// Built inside RequestTracingMiddleware after each request completes. /// public sealed record ObservabilityRecord { public string? TraceContext { get; init; } public string? CorrelationId { get; init; } public string ServiceName { get; init; } = "GB5"; public string OperationName { get; init; } = string.Empty; public int? EventTypeId { get; init; } public int DurationMs { get; init; } public int StatusCode { get; init; } public bool IsLowPerformance { get; init; } public bool IsError { get; init; } public string? ErrorType { get; init; } public int? RequestSize { get; init; } public int? ResponseSize { get; init; } public int TenantId { get; init; } = -1; public int? UserId { get; init; } public string? SessionId { get; init; } public int? DiagnosticSessionId { get; init; } public DateTime CreatedOn { get; init; } = DateTime.UtcNow; }