mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-14 20:21:09 +02:00
feat(monitoring): structured logging, Promtail alignment, GlitchTip config, status page
- Upgrade shared-logger to dual-mode: JSON lines in production, console in dev. Adds configureLogger() for service name + request ID. - Add requestLogger middleware to shared-hono with request ID generation and structured request/response logging. - Align Promtail config with new JSON field names (requestId, ts, service). - Add PUBLIC_GLITCHTIP_DSN + PUBLIC_UMAMI_WEBSITE_ID to mana-web docker config. - Add /status page that polls all backend /health endpoints server-side. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
7ba82472b2
commit
7908995a29
5 changed files with 589 additions and 345 deletions
|
|
@ -97,16 +97,18 @@ scrape_configs:
|
|||
method: method
|
||||
path: path
|
||||
duration: duration
|
||||
request_id: request_id
|
||||
request_id: requestId
|
||||
service_name: service
|
||||
# Fall back: extract level from common log patterns
|
||||
- regex:
|
||||
expression: '(?i)(?P<level>error|warn|info|debug|fatal|panic)'
|
||||
# Normalize level label
|
||||
- labels:
|
||||
level:
|
||||
service_name:
|
||||
# Add timestamp from log if available
|
||||
- timestamp:
|
||||
source: time
|
||||
source: ts
|
||||
format: RFC3339Nano
|
||||
fallback_formats:
|
||||
- "2006-01-02T15:04:05.000Z"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue