Feat/monitoring#6
Merged
Merged
Conversation
logstash-logback-encoder 7.4, micrometer-tracing-bridge-otel, opentelemetry-exporter-otlp Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- logback-spring.xml: JSON via LogstashEncoder for non-local profiles, human-readable for local; includes traceId, spanId, userId MDC keys - IdentityMdcFilter: populates MDC userId from X-User-Id header, always cleans up in finally (4 tests covering edge cases) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Sampling probability via TRACING_SAMPLING_PROBABILITY env var (default 1.0). Exports traces to Grafana Tempo at http://tempo:4318/v1/traces. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Central @component wrapping MeterRegistry. Tag-less counters pre-registered in constructor so they appear in /actuator/prometheus before the first event fires. Tagged counters (login outcome, failure reason, etc.) remain lazy builders. 14 unit tests via SimpleMeterRegistry. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
… and metrics - Structured log statements (info/warn/debug) with no sensitive data logged - IdentityMetrics injected into all 9 services + 2 event handlers - login: distinguishes user_not_found vs invalid_credentials failure reasons - token refresh: 'rotation' tag (not 'logout') on revoked session metric - password reset handler: try/catch so async DB failure is logged not swallowed - Existing tests updated to pass IdentityMetrics (SimpleMeterRegistry); new metrics tests for LoginService and RegisterUserService Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Config: OTLP HTTP on 4318, local filesystem storage, query API on 3200. docker-compose: tempo service with named volume. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Loki: schema v13, TSDB index, filesystem storage on port 3100. Promtail: Docker socket + container log volume discovery (macOS and Linux compatible); pipeline extracts level, traceId, spanId from JSON logs. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Datasources: Prometheus (default), Loki (uid: loki, traceId derived field → Tempo), Tempo (uid: tempo, tracesToLogsV2 → Loki, service map → Prometheus). Dashboards folder provider + 3 JSON skeletons: identity-health, identity-business, identity-errors. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
6 rules: IdentityServiceDown, HighLoginFailureRate, PasswordResetAbuse, HighHttpErrorRate, SlowResponses, DBConnectionPoolExhausted. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- Tempo, Loki, Promtail services with named volumes - Grafana provisioning volume mount and depends_on (prometheus, loki, tempo) - Prometheus rules volume mount - identity-service: TRACING_SAMPLING_PROBABILITY env var Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
🧪 Test Results234 tests 234 ✅ 13s ⏱️ Results for commit 468709f. |
📊 Code Coverage Report
Files
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.