agentleFS
huialihuiali/rust-skills/skills/rust-observability/SKILL.md

rust-observability

Skill47 starsChanged 9 months agoMITView on GitHub

Which telemetry signals reduce mean time to detect and resolve production failures? Use all three intentionally, not interchangeably.

We split this skill into the rules it gives an agent

4 rules. 0 are common, 3 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 3 edited versions we read keep these.

  • 3

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use all three intentionally, not interchangeably.

    line 17
  2. Very specific:

    No secrets/tokens/PII leakage.

    line 29
  3. Distinctive:

    Keep label cardinality bounded.

    line 34
  4. Distinctive:

    Prefer RED + USE style baseline metrics.

    line 35

“Common” is measured: kept by at least 6 in 10 of the 3 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

name: rust-observability description: "Rust observability skill for tracing, metrics, structured logging, OpenTelemetry pipelines, and production incident diagnostics."---

Rust Observability Skill

Core Question

Which telemetry signals reduce mean time to detect and resolve production failures?

Signal Model

- Logs: contextual events and state snapshots. - Traces: cross-service causal path and latency breakdown. - Metrics: rate/error/duration + saturation and capacity.

Use all three intentionally, not interchangeably.

Instrumentation Priorities

1. Request entry/exit and key business operations. 2. Downstream calls (DB, cache, RPC, queue). 3. Retry/timeouts and circuit-breaker transitions. 4. Queue depth and worker saturation.

Logging Rules

- Structured logs only. - No secrets/tokens/PII leakage. - Stable field names for dashboards and alerts.

Metrics Rules

- Keep label cardinality bounded. - Prefer RED + USE style baseline metrics. - Track queue/worker/resource saturation explicitly.

Common Pitfalls

- High-cardinality labels (raw user/session IDs). - Verbose debug logs on hot paths in production. - Traces without propagated correlation context. - Alert thresholds not aligned with SLOs.

Review Checklist

- [ ] Critical path spans and error fields exist. - [ ] Metrics cover latency/errors/saturation. - [ ] Correlation IDs flow across service boundaries. - [ ] Logging policy prevents sensitive data exposure. - [ ] Alerts map to actionable runbooks.

Verification Commands

cargo check
cargo test
cargo clippy
RUST_LOG=info cargo run

Related Skills

- rust-web - rust-database - rust-concurrency

Localized Reference

- Original Chinese version is preserved in SKILL_ZH.md.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

Reviews can't be read right now.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.