agentsclimarketplace

Observability

Skill iceflower/agent-skills/observability

Agent Skills 오픈 표준 기반 AI 코딩 에이전트용 스킬 컬렉션 (Java, Kotlin, Spring, NestJS, K8s, Terraform, GraphQL, gRPC, OpenTelemetry, a11y, i18n 등 60개)

Install
npx -y skills add iceflower/agent-skills --skill observability

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

What its author says it does

Copied from the file, not written here

Modern observability and monitoring patterns centered on OpenTelemetry (OTel). Covers the three pillars (traces, metrics, logs) with context propagation, OTel SDK architecture, OTLP protocol, distributed tracing with W3C Trace Context, metric instrument types (Counter, Histogram, Gauge, Timer, Exemplars), key metrics to monitor (application, business, infrastructure), metric naming conventions, log correlation, OTel Collector pipelines, Semantic Conventions, backend integration (Jaeger, Grafana Tempo, Loki, Prometheus), alerting rules, health check patterns (liveness, readiness, startup), SLO/SLI design, error budget management, and business metrics modeling. Use when implementing distributed tracing, setting up OTel instrumentation, configuring Collector pipelines, designing alerting strategies, implementing health checks, defining SLO/SLI targets, or integrating observability backends.

The file declares its own license as MIT. That is the author’s claim about this one file, and it is not the same thing as the license GitHub reports for the repository, which is listed with the other numbers below.

SKILL.md

14.8 KB, ~3.3k tokens by cl100k_base, as published. Nobody here has run it

Observability Rules (OpenTelemetry)

1. Core Concepts

OpenTelemetry provides a unified standard for collecting telemetry data.

Three Pillars + Context

SignalPurposeRole in Debugging
TracesRequest flow across servicesWhere it went wrong (which service/span)
MetricsAggregated measurements over timeSomething is wrong (alert trigger)
LogsDiscrete event recordsWhat went wrong (error details)
ContextCorrelates all signals via trace ID, span IDConnect all three for correlated debugging

Architecture

[Application + OTel SDK]
    |-- API (instrumentation interface)
    |-- SDK (implementation: sampling, batching, export)
    |-- Auto-instrumentation (zero-code)
         |
    [OTel Collector] (optional but recommended)
    |-- Receivers  → Processors → Exporters
         |
    [Backends: Jaeger, Tempo, Prometheus, Loki]

OTLP Protocol

TransportPortUse Case
gRPC4317Default, binary protobuf
HTTP4318Firewalls, load balancers

Endpoints: /v1/traces, /v1/metrics, /v1/logs

2. Distributed Tracing

Span Structure

A span represents a unit of work with:

  • Span Context: trace ID, span ID, trace flags (immutable)
  • Attributes: key-value metadata (http.request.method, db.system)
  • Events: timestamped annotations within the span
  • Links: causal relationships to other spans (async flows)
  • Status: Unset (default), Error, Ok

SpanKind

KindDirectionExample
ClientOutbound syncHTTP client, DB client
ServerInbound syncHTTP server handler
InternalIn-processBusiness logic
ProducerOutbound asyncQueue publish
ConsumerInbound asyncQueue consume

W3C Trace Context Propagation

traceparent: 00-<trace-id>-<span-id>-<trace-flags>
tracestate:  vendor-specific data
  • Default propagator in OTel
  • Inject on outgoing requests, extract on incoming
  • Never propagate internal trace data to untrusted external services
  • Never put sensitive data in Baggage

Instrumentation Approaches

ApproachEffortCoverage
Auto (zero-code)NoneFrameworks, HTTP, DB, messaging
Manual (code-based)MediumCustom business logic spans
Library instrumentationLowThird-party library support

Rule: Start with auto-instrumentation, add manual spans only for business-critical operations that auto-instrumentation doesn't cover.

3. Metrics

Instrument Types

TypeMonotonicSyncUse Case
CounterYesSyncRequest count, bytes sent
UpDownCounterNoSyncQueue size, active connections
HistogramN/ASyncRequest duration, response size
GaugeN/ASyncCPU temperature, memory usage
Observable*VariesAsyncCollected once per export cycle

Timer note: Some frameworks (e.g., Micrometer) provide a Timer type that combines duration measurement with count. In OTel, use a Histogram instrument for the same purpose (e.g., http.server.request.duration).

Exemplars

Link metrics to traces for drill-down from aggregated data to individual requests.

  • Attach trace ID / span ID to metric measurements
  • Configure with TraceBased exemplar filter
  • Visualized as diamond markers in Grafana
  • Enables: "This p99 latency spike → show me the exact trace"

Views

Customize metric processing per instrument:

  • Select which instruments to process
  • Override aggregation strategy (e.g., explicit bucket histogram)
  • Filter or rename attributes
  • Set aggregation temporality

Metric Naming Convention

# OTel standard: dot-separated, lowercase, include unit
http.server.request.duration
db.client.operation.duration

# Domain-specific pattern: <domain>.<entity>.<action>
orders.created.total
payments.processing.duration
users.active.count
cache.hits.total

Use standard units: s (seconds), By (bytes), {request} (count).

Key Metrics to Monitor

Application Metrics

MetricAlert ThresholdSeverity
HTTP error rate (5xx)> 1% of requestsCritical
HTTP P99 latency> 3x baselineWarning
Heap/memory usage> 85%Warning
GC pause time> 500msWarning
Thread pool active threads> 90% capacityWarning
DB connection pool exhaustion> 90% usedCritical

Business Metrics

MetricPurpose
Orders per minuteBusiness throughput
Payment success rateRevenue impact
User login rateTraffic pattern
API call count by endpointUsage analytics

Infrastructure Metrics

MetricAlert Threshold
CPU usage> 80% sustained
Memory usage> 85%
Disk I/O> 80% utilization
Pod restart count> 0 unexpected

4. Logs

OTel does not replace existing logging frameworks. It bridges them.

Integration Pattern

[Application Code]
    → [Logging Framework (Logback, Log4j, winston)]
        → [OTel Log Appender/Bridge]
            → [OTel SDK LogRecordProcessor]
                → [OTel Collector or Backend]

Log-Trace Correlation

When OTel SDK is active, trace ID and span ID are automatically injected into log records. No code changes required.

{
  "timestamp": "2026-03-24T10:30:00Z",
  "severity": "ERROR",
  "body": "Payment processing failed",
  "traceId": "abc123...",
  "spanId": "def456...",
  "attributes": {
    "user.id": "42",
    "order.id": "ORD-789"
  }
}

Log Rules

  • Use structured logging (JSON) for machine readability
  • Let OTel SDK inject trace context automatically
  • Do not call the Logs Bridge API directly from application code
  • Configure log appenders for your framework (Logback, Log4j2, Python logging)

5. OTel Collector

The Collector is a vendor-agnostic proxy that receives, processes, and exports telemetry data. For detailed pipeline configuration, see references/otel-collector.md.

Deployment Patterns

PatternDescriptionWhen to Use
No CollectorApp exports directly to backendDev/test only
Agent (sidecar)Collector beside each serviceFast offloading, local processing
GatewayCentralized Collector clusterMulti-source collection, routing

Recommendation: Use Agent mode in production for reliability. Gateway mode for cross-cluster aggregation and routing.

Essential Processors

ProcessorPurpose
batchBuffer and send in batches (reduces network overhead)
memory_limiterPrevent OOM (always configure — set limit_mib to ~80% of container memory)
attributesAdd, update, delete, hash attributes
filterDrop unwanted telemetry
tail_samplingSample based on complete trace (Collector only)
resourceAdd resource attributes

6. Semantic Conventions

Use standard attribute names for interoperability across tools and dashboards. For the full convention list, see references/semantic-conventions.md.

Key Conventions (Summary)

DomainKey Attributes
HTTPhttp.request.method, http.response.status_code, url.path, http.route
Databasedb.system, db.operation.name, db.collection.name
Messagingmessaging.system, messaging.operation.type, messaging.destination.name
RPCrpc.system, rpc.service, rpc.method

7. SDK Patterns

For detailed setup examples by language (Java, Node.js, Python), see references/otel-sdk-patterns.md.

Quick Reference

LanguageZero-CodeManual
Java-javaagent:opentelemetry-javaagent.jarGlobalOpenTelemetry.getTracer()
Java (Spring Boot 4.0+)spring-boot-starter-opentelemetrySpring-integrated config
Node.js@opentelemetry/auto-instrumentations-nodetrace.getTracer()
Pythonopentelemetry-instrument CLItrace.get_tracer()

8. Backend Integration

Recommended Stack (Grafana)

Traces  → Grafana Tempo  (OTLP native)
Metrics → Prometheus      (OTLP receiver or remote write)
Logs    → Grafana Loki    (OTLP native, Loki 3.0+)
UI      → Grafana         (unified query across all signals)

Jaeger

  • Jaeger v2 uses OTel Collector as its core pipeline
  • OTLP endpoints: gRPC 4317, HTTP 4318
  • jaegertracing/all-in-one Docker image for dev

Prometheus OTLP

# Enable OTLP receiver
prometheus --web.enable-otlp-receiver
# OTel SDK environment variables
OTEL_EXPORTER_OTLP_PROTOCOL=http/protobuf
OTEL_EXPORTER_OTLP_METRICS_ENDPOINT=http://localhost:9090/api/v1/otlp/v1/metrics

9. Alerting

Design alerts around symptoms, not causes. For detailed alerting rules, severity levels, and templates, see references/alerting-rules.md.

Key Principles

  • Alert on symptoms (error rate, latency), not causes (CPU, memory)
  • Every alert must have a runbook or action item
  • Avoid alert fatigue — only alert on actionable conditions
  • Use multi-window or burn-rate alerts over simple thresholds
  • Include context in alert messages (service, environment, metric value)

Alert Severity Summary

LevelResponse TimeExample
CriticalImmediateService down, data loss risk
WarningWithin 1 hourDegraded performance
InfoNext business dayApproaching threshold

10. Health Checks

Health checks enable orchestrators (Kubernetes, load balancers) to manage application lifecycle. For detailed probe configuration and rules, see references/health-checks.md.

Probe Types

ProbeCheckExternal Dependencies
LivenessApp is runningNo
ReadinessApp can serve trafficYes (DB, cache)
StartupApp initialization doneYes

Key Rules

  • Liveness probes must be lightweight — no external dependency checks
  • Readiness probes should verify critical dependencies
  • Never put slow checks in liveness probes (causes unnecessary restarts)
  • Health checks must not cause side effects (writes, external calls)

11. Common Anti-Patterns

Anti-PatternProblemFix
No sampling in productionStorage explosionUse head or tail sampling
High-cardinality attributes in metricsMetric/index explosionLimit metric attribute values, use Views to filter
Sensitive data in spansSecurity/compliance riskRedact PII with attribute processor
Skipping CollectorNo buffering, sampling, or routingDeploy Collector in Agent mode
Ignoring Semantic ConventionsInconsistent dashboards/alertsFollow OTel standard names
No memory_limiter processorCollector OOMAlways configure memory limits
Manual trace propagationBroken traces, missing contextUse SDK auto-propagation
Logging trace ID manuallyDuplicate/inconsistent IDsLet OTel SDK inject automatically
Alerting on every errorAlert fatigueAlert on error rate instead
Missing traceId in logsBreaks correlationEnable OTel log bridge
Dashboard with 50+ panelsInformation overloadFocus on key signals per dashboard
No baseline metricsCannot detect regressionsEstablish baselines before alerting
Monitoring only infra, not businessMiss revenue-impacting issuesAdd business metrics

12. SLO/SLI Design

Service Level Objectives (SLOs) and Indicators (SLIs) translate reliability into measurable targets. For detailed design patterns, see references/slo-sli-design.md.

SLI Selection Framework

Request TypeRecommended SLIs
User-facing APIsAvailability, Latency (p99), Error rate
Background jobsFreshness, Throughput, Error rate
Data pipelinesCompleteness, Freshness, Accuracy
Storage systemsDurability, Availability, Latency

SLO Design Rules

  • Set SLO targets based on user pain thresholds, not current performance — aspire and improve
  • Define error budget = (1 - SLO) × time window; consume it deliberately on features, not incidents
  • Use multi-window multi-burn-rate alerts (5m + 1h short window, 30m + 6h long window)
  • Review and adjust SLOs quarterly — SLOs should reflect current user expectations
  • Start conservative (e.g., 99.0%) and tighten as reliability improves

Error Budget Policy

Budget RemainingAction
> 50%Ship features freely
25–50%Review risky changes
10–25%Freeze non-critical deploys
< 10%Incident review required before any deploy
0%Reliability work only until budget restored

13. Related Skills

  • logging: Structured logging and monitoring integration
  • incident-response: Alert-driven incident response processes
  • troubleshooting: Monitoring data-driven problem diagnosis
  • spring-framework: Spring Boot Actuator and Micrometer metrics

Additional References

Gives 1 of the 12 instructions most monitoring observability skills give in ~3.3k tokens

Counted across 481 of the 483 authors here whose files we hold, read 2026-08-06

  • link every alert to a runbookin 43 of 481, across 35 files
  • use structured json logginghere, and in 36 of 481, across 31 files
  • alert on user-facing symptomsin 20 of 481, across 15 files
  • emit structured JSON logs with stable event namesin 18 of 481, across 13 files
  • propagate trace context across boundariesin 16 of 481
  • use histograms for latency trackingin 14 of 481, across 9 files
  • use OpenTelemetry for distributed tracingin 13 of 481, across 8 files
  • include a correlation ID on every log linein 13 of 481, across 8 files
  • Define service level objectivesin 10 of 481, across 7 files
  • Call useAzureMonitor before importing other modulesin 9 of 481, across 2 files
  • stop and ask for clarification if inputs are missingin 9 of 481, across 2 files
  • define on-call questions before adding telemetryin 9 of 481, across 4 files

Said here and by no other author read

  • use standard units for metrics
  • let the SDK inject trace context
  • configure log appenders for the framework
  • use agent mode in production
  • always configure memory limits

Grouped from the skills themselves: near-identical wordings counted once, and counted by distinct author, so one author publishing three of these counts once. Length counted with cl100k_base; the agent that loads this file may tokenize it differently.

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.