observability

Implements structured logging, Prometheus metrics, OpenTelemetry tracing, alerting rules, and SLO dashboards.

1|Updated Mar 18, 2026
One-click install
npx skills add https://github.com/MARUCIE/openclaw-foundry --skill observability-marucie
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: observability
Source: https://github.com/MARUCIE/openclaw-foundry/tree/main/web/public/packs/spellbook-security-auditor/skills/observability
Command: npx skills add https://github.com/MARUCIE/openclaw-foundry --skill observability-marucie

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Production systems often lack the instrumentation needed to diagnose failures, trace requests across services, and detect incidents before users report them. This Skill provides a complete observability playbook covering logs, metrics, traces, alerts, SLOs, and dashboards so teams can understand system behavior from external outputs. ## Core Features & Use Cases - Structured Logging Standards: Enforces JSON logs with mandatory fields (timestamp, trace_id, request_id) and correlation ID propagation across services and async queues, with code examples in Python (structlog), TypeScript (pino), and Go (slog). - Metrics and Tracing: Defines Prometheus metric naming, label cardinality rules, RED/USE methods, and OpenTelemetry distributed tracing setup with sampling strategies. - Alerting, SLOs, and Dashboards: Provides symptom-based alert design, error budget policies, burn rate alerting, and a Grafana golden-signals dashboard template. - Use Case: When adding observability to a new payment service, use this Skill to instrument structured logs, expose RED metrics, wire OpenTelemetry tracing, and create alert rules with runbook links. ## Quick Start Use the observability skill to instrument my payment service with structured logging, Prometheus RED metrics, and OpenTelemetry tracing.

Frequently Asked Questions about observability

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add structured logging to a Python service?▼

Use structlog with a TimeStamper and JSONRenderer processor configured once at startup. Bind context like service name and request_id, then emit logs as JSON with mandatory fields including timestamp, level, trace_id, and message.

What Prometheus metric type should I use for request latency?▼

Use a Histogram for latency metrics, not a Summary. Histograms can be aggregated across instances in PromQL using histogram_quantile, while Summaries calculate quantiles client-side and cannot be aggregated across replicas.

Why does high label cardinality crash Prometheus?▼

Each unique label combination creates a new time series, so labels like user_id or raw URL paths can generate millions of series and exhaust memory. Use only low-cardinality labels such as HTTP method, normalized endpoint, and status code.

How do I propagate trace context across microservices?▼

Use the W3C traceparent header for HTTP and gRPC calls, and generate the request_id once at the edge. Pass it downstream via X-Request-ID headers and embed correlation_id in message payloads for async queues.

What is burn rate alerting for SLOs?▼

Burn rate measures how fast you consume your error budget relative to the sustainable pace. Alert at 14x burn over 1 hour or 6x over 6 hours as critical, and at 3x over 1 day or 1x over 3 days as warnings.

Should I alert on CPU usage or error rates?▼

Alert on symptoms like error rate and latency that directly affect users, not causes like CPU usage which can spike without user impact. Use resource metrics only for capacity forecasting, and always add a for: duration to avoid flapping.