Observability Instrumentation

中级ops最低上下文:32K

Adds production-grade observability to a codebase by instrumenting it with structured logs, metrics, and distributed traces. Recommends span boundaries, cardinality-safe labels, and OpenTelemetry conventions, then generates the wiring code and dashboards needed to make a service debuggable in production.

使用场景

  • Adding OpenTelemetry tracing to an existing service
  • Defining metrics and SLIs for a new API
  • Reducing metric cardinality that is blowing up costs
  • Standardizing structured logging across microservices

示例提示词

Instrument this Express.js service with OpenTelemetry. Add distributed tracing around the
route handlers and database calls, emit request-rate/error-rate/latency metrics, and switch
console logs to structured JSON logs with a trace_id field. Explain span boundaries and any
cardinality risks in the labels you choose.

```
[paste service code here]
```

推荐模型

兼容工具

claude-codecursorkiroany

模态

输入: code, text
输出: code, text

相关 Skills

作者

OpenModels Community

@openmodelsrun