Employee Observability
Summary
Employee Service uses shared-kernel structured JSON console logging, correlation middleware, OpenTelemetry resource identity, inbound request tracing, outbound HTTP tracing, exception recording, and optional trace exporters.
Audience
- Backend developers and QA engineers
- DevOps engineers and solution architects
Reference Content
Logging
Shared observability clears default logging providers and installs JSON console logging. Logs use UTC timestamps, include scopes, and carry the configured service identity. Application code logs startup seed failures and the shared outbox processor logs publication failures when invoked.
Correlation
Correlation middleware accepts an existing correlation identifier or generates one, stores it in request context, returns it with the response, and adds correlation/service identity to the logging scope.
Tracing
OpenTelemetry configures service resource identity, ASP.NET Core request instrumentation, HTTP client instrumentation, and exception recording. Console and OTLP trace export are configuration-controlled. Employee currently registers no outbound HTTP client, but the shared instrumentation is available.
Metrics
No WithMetrics pipeline, custom Employee metric, or metrics exporter was found. Metrics support is therefore Not implemented in reviewed source.
Structured logging boundary
The source configures structured host logs, but it does not define a dedicated Employee log schema, audit-to-log projection, sensitive-data redaction policy, dashboard, alert, or service-level objective. Those areas Require confirmation.
Observability flow
Source References
microservices/src/employee-service/Program.csmicroservices/src/shared-kernel/Extensions/ObservabilityExtensions.csmicroservices/src/shared-kernel/Middleware/CorrelationIdMiddleware.csmicroservices/src/shared-kernel/Messaging/OutboxProcessor.cs
Related Articles
See Also
Keywords
- JSON logging
- Distributed tracing
- Correlation scope
Revision Information
- Status: Draft
- Last reviewed: 2026-07-15
- Review cycle: Quarterly