
rust-observability
Instrument, operate, and review Rust applications with tracing spans and events, structured logs, metrics, OpenTelemetry context propagation, Prometheus export, sampling, correlation, redaction, cardinality control, tokio-console diagnostics, and graceful telemetry shutdown. Use when users ask for logging, distributed traces, service metrics, request correlation, async task diagnosis, SLO evidence, or production observability architecture.
- Installs
- 113
- Last 24h
- —
- Trending rank
- —
- Security
- Not audited
Install
Works with every agent the skills CLI supports.
npx skills add https://github.com/full-stack-skills/rust-skills --skill rust-observability- 01
Install
Run the command in your project. The CLI asks which agents to install for.
- 02
Describe the task
Ask your agent for something this skill covers. It loads rust-observability automatically when relevant.
- 03
Review the result
The agent follows the SKILL.md steps, scripts and references bundled with the skill.
SKILL.md
The instructions your agent reads when the skill is triggered.
Rust Observability
Design telemetry from operational questions and failure modes. Logs explain discrete events, traces connect work across boundaries, metrics quantify behavior over time, and profiles diagnose resource consumption. Do not emit all data to all signals.
Scope and Routing
Use this skill for tracing, subscribers, structured logs, metrics, OpenTelemetry, context propagation, sampling, exporters, request correlation, async runtime diagnostics, redaction, and shutdown flushing.
Route concurrency correctness to rust-concurrency, HTTP middleware to rust-web, security event policy to rust-web-security, performance profiling to rust-performance, and dependency features to rust-cargo-build.
Workflow
1. Start from decisions and SLOs
List the questions operators must answer: request rate and latency, error categories, saturation, queue depth, retries, dependency health, task leaks, resource usage, and deployment identity. Define service name, environment, version, instance attributes, ownership, retention, access control, and cost budgets before selecting exporters.
2. Establish structured tracing
Use tracing spans for operations with duration and nested work; use events for facts occurring at a point in time.
use tracing::{info, instrument};
#[instrument(skip(payload), fields(job.id = job_id))]
async fn process(job_id: u64, payload: &[u8]) {
info!(payload.len = payload.len(), outcome = "accepted");
}
- Name spans and fields consistently using domain meaning.
- Skip secrets, bodies, credentials, raw SQL values, and large payloads.
- Record stable error categories and outcomes instead of only formatted messages.
- Ensure instrumented futures are entered during polling, not by holding a span guard across
.awaitincorrectly. - Configure filtering and formatting at the application boundary, not inside libraries.
Read Tracing and Structured Logs.
3. Design bounded metrics
Choose counters for totals, gauges for current state, and histograms for distributions. Record throughput, latency, errors, saturation, queue wait, retries, rejections, and resource pools using stable low-cardinality labels.
Never use user IDs, request IDs, URLs with raw paths, SQL text, arbitrary error messages, or unbounded tenant IDs as metric labels. Define histogram units and buckets from SLOs. Read Metrics and Cardinality.
4. Propagate distributed context
Extract remote trace context only from trusted transport formats, create server or consumer spans, and inject current context into outbound requests or messages. Preserve causal relationships across spawned tasks deliberately; detached background work may need a link rather than an inherited parent.
Use OpenTelemetry only when interoperability or vendor-neutral export is required. Check signal maturity, crate versions, runtime requirements, batch behavior, and exporter compatibility. Read OpenTelemetry and Context.
5. Configure pipelines and shutdown
- Compose subscribers and layers once at process startup.
- Make filters reloadable only with authenticated and audited controls.
- Bound exporter queues and define drop or backpressure behavior.
- Sample traces with an explicit policy; keep errors and rare paths observable without making success traffic unaffordable.
- Flush or shut down telemetry providers within the service shutdown deadline.
- Avoid recursive telemetry from exporters using the same instrumented network path.
6. Validate telemetry behavior
Test field names, levels, error categories, context propagation, redaction, cardinality, disabled-subscriber behavior, exporter failure, queue saturation, and shutdown flushing. Use a test subscriber or in-memory exporter rather than asserting unstable formatted lines.
Use tokio-console in diagnostic builds to find long polls, resource waits, and leaked tasks; do not expose its control endpoint publicly. Read Runtime and Operations.
Completion Criteria
- Tie every signal to an operational question or SLO.
- Use structured spans and events with stable fields and explicit redaction.
- Keep metric labels bounded and histogram units defined.
- Propagate trace context across supported inbound, outbound, and messaging boundaries.
- Bound exporter cost, queues, sampling, and shutdown time.
- Test telemetry as behavior without coupling to one text formatter or vendor.
Resources
- Tracing and Structured Logs
- Metrics and Cardinality
- OpenTelemetry and Context
- Runtime and Operations
- Execution Scenarios
examples/golden-observability/: a compiled custom tracing layer contract.
Upstream Sources
Data Privacy
This skill does not collect, store, or transmit user data. Telemetry changes can transmit production data; confirm authorization, destinations, retention, redaction, and access controls before enabling exporters.
FAQ
What does the rust-observability skill do?
Instrument, operate, and review Rust applications with tracing spans and events, structured logs, metrics, OpenTelemetry context propagation, Prometheus export, sampling, correlation, redaction, cardinality control, tokio-console diagnostics, and graceful telemetry shutdown. Use when users ask for logging, distributed traces, service metrics, request correlation, async task diagnosis, SLO evidence, or production observability architecture.
How do I install rust-observability?
Run npx skills add https://github.com/full-stack-skills/rust-skills --skill rust-observability in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/rust-observability/ (personal) or .claude/skills/rust-observability/ (project).
Which AI agents can use rust-observability?
Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.
Is rust-observability safe to install?
No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.
Who maintains rust-observability?
It is published by full-stack-skills in full-stack-skills/rust-skills. It has 113 recorded installs.
More from full-stack-skills/rust-skills
rust-testing
full-stack-skills/rust-skills
Design, implement, and validate Rust tests, including unit, integration, doctest, compile-fail, property, fuzz, benchmark, coverage, async, concurrency, process, daemon, IPC, terminal, platform, and hardware-facing test strategies. Use when users ask for Rust test architecture, flaky-test diagnosis, coverage gates, benchmarks, trybuild, cargo-nextest, real-process tests, or failure-path verification.
rust-concurrency
full-stack-skills/rust-skills
Open the skill to read its SKILL.md instructions.
rust-style-clippy
full-stack-skills/rust-skills
Open the skill to read its SKILL.md instructions.
rust-performance
full-stack-skills/rust-skills
Measure, profile, optimize, and regression-test Rust performance across latency, throughput, CPU, allocations, memory, binary size, and compile time using representative workloads, Criterion, iai-callgrind, cargo-flamegraph, samply, DHAT, heap or pprof tools, cargo-bloat, cargo-llvm-lines, and build timings. Use when users report slow Rust code, high memory or CPU, large binaries, noisy benchmarks, tail-latency regressions, or need performance budgets and evidence-backed optimization.
rust-code-review
full-stack-skills/rust-skills
Review Rust changes for correctness, memory and thread safety, error semantics, unnecessary allocation or cloning, lock scope, API compatibility, test gaps, documentation, and dependency risk, applying the Rust API Guidelines checklist (C-PANIC, C-UNWRAP, C-TRANSMUTE, C-BOOL, C-NEWTYPE, C-COMMON-TRAITS, C-CONVERT, C-SEALED, C-NON-EXHAUSTIVE). Use when reviewing Rust diffs, pull requests, libraries, unsafe boundaries, or production incidents; report actionable findings by severity before summaries, route automated formatting or lint policy to rust-style-clippy, and route API shape decisions (trait sealing, error taxonomy, newtype design, builder patterns) to rust-api-design.
rust-cargo-build
full-stack-skills/rust-skills
Open the skill to read its SKILL.md instructions.
Popular backend & apis skills
find-skills
vercel-labs/skills
Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", or express interest in extending capabilities. This skill should be used when the user is looking for functionality that might exist as an installable skill.
entra-app-registration
microsoft/azure-skills
Guides Microsoft Entra ID app registration, OAuth 2.0 authentication, and MSAL integration. USE FOR: create app registration, register Azure AD app, configure OAuth, set up authentication, add API permissions, generate service principal, MSAL example, console app auth, Entra ID setup, Azure AD authentication. DO NOT USE FOR: Key Vault secrets (use azure-keyvault-expiration-audit), general Azure resource security guidance.
google-agents-cli-adk-code
google/agents-cli
This skill should be used when the user wants to "write agent code", "build an agent with ADK", "add a tool", "create a callback", "define an agent", "use state management" — in a project that needs ADK (Agent Development Kit) API patterns and code examples. It provides a quick reference for agent types, tool definitions, orchestration patterns, callbacks, state management, the graph Workflow API, and reference recipes to study. Do NOT use for scaffolding (use google-agents-cli-scaffold) or deployment (use google-agents-cli-deploy).
embedded-captions
heygen-com/hyperframes
Add captions or subtitles to an existing single-subject talking-head video without editing the footage. Use for plain verbatim captions, cinematic captions embedded behind the subject, VFX captions, “炸/特效/酷炫字幕,” or a named identity from the 35-style catalog. Route by visual identity, not by backend engine. The quiet anchor rail is the default; embed every word only when the user explicitly wants a fully cinematic treatment. The workflow runs locally end to end, including transcription and subject matting; split multi-shot footage before applying it.
entra-agent-id
microsoft/azure-skills
Provision Microsoft Entra Agent Identity Blueprints, BlueprintPrincipals, and per-instance Agent Identities via Microsoft Graph, and configure OAuth 2.0 token exchange (fmipath, OBO, cross-tenant) including the Microsoft Entra SDK for AgentID sidecar. USE FOR: Agent Identity Blueprint, BlueprintPrincipal, agent OAuth, fmipath token exchange, agent OBO, Workload Identity Federation for agents, polyglot agent auth, Microsoft.Identity.Web.AgentIdentities. DO NOT USE FOR: standard Entra app registration (use entra-app-registration), Microsoft Foundry agent authoring (use microsoft-foundry).
neon
neondatabase/agent-skills
Overview of Neon, a complete set of cloud backend primitives around Lakebase Postgres: Auth, Object Storage, Functions, the AI Gateway, and Realtime. Start here to choose Neon for undecided login, files, APIs, and LLM calls, set up the CLI or MCP server, and follow the branch-first workflow. Use when building an app or backend on Neon, or when "Neon" or "Lakebase Postgres" is mentioned. Child skill neon-postgres wins for an existing DATABASEURL, SQL, schema, inspect, or search. Child skill neon-auth wins for login, users, sessions, identity routing, and Managed Better Auth setup. Child skill neon-realtime wins for live queries in reactive apps and agents. Also use for object storage, S3, buckets, serverless functions, function triggers, cron, AI gateway, LLM calls, realtime, logs, Loki, Grafana, observability, postgres, database, backend, Claimable Neon, neon.new, or a no-signup database.