logging-observability

Implement structured JSON logging with correlation IDs for Python and TypeScript applications.

783|62|Updated Jan 19, 2026
One-click install
npx skills add https://github.com/dadbodgeoff/drift --skill logging-observability-dadbodgeoff
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: logging-observability
Source: https://github.com/dadbodgeoff/drift/tree/main/drift%20v1%20depreciated/skills/logging-observability
Command: npx skills add https://github.com/dadbodgeoff/drift --skill logging-observability-dadbodgeoff

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill addresses the challenge of understanding application behavior by providing structured, context-rich logging that simplifies debugging, performance monitoring, and request tracing across distributed systems.

Core Features & Use Cases

  • Structured JSON Logging: Ensures logs are machine-readable for easy aggregation and analysis.
  • Correlation IDs: Enables tracing a single request or job across multiple services or asynchronous operations.
  • Context Propagation: Carries request-specific metadata (like user ID, path) through the application stack, even across async boundaries.
  • Performance Timing: Decorators automatically log the duration of operations, highlighting performance bottlenecks.
  • Use Case: Debugging a complex API request that involves multiple microservices by following its unique correlation ID through all the logs.

Quick Start

Configure the Python logging system to use structured JSON output with a specified service name and environment.

Frequently Asked Questions about logging-observability

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

FAQPage Schema
How do I implement structured JSON logging with context propagation in Python?▼

Structured JSON logging with context propagation is implemented by utilizing Python contextvars to manage request-scoped data, ensuring metadata like user IDs and paths carries through async boundaries for machine-readable log aggregation.

How do I trace a request across microservices using correlation IDs?▼

Tracing a request across microservices uses correlation IDs embedded in structured JSON logs. This enables following a single request or job through multiple services and asynchronous operations for simplified distributed system debugging.

Does structured logging work with TypeScript and AsyncLocalStorage for context propagation?▼

Structured logging works with TypeScript and JavaScript applications by requiring AsyncLocalStorage to manage request-scoped data. This ensures context propagation carries request-specific metadata across asynchronous boundaries effectively.

What is the best way to measure operation duration and identify performance bottlenecks in Python?▼

Measuring operation duration to identify performance bottlenecks is handled by performance timing decorators. These automatically log the duration of operations, highlighting performance issues within your application stack.

Can I collect worker metrics and analyze application behavior without complex tracing setups?▼

Collecting worker metrics and analyzing application behavior is facilitated by structured, context-rich logging. This approach provides deep insights into application performance and simplifies debugging without requiring complex standalone tracing infrastructure.

Why do I need contextvars for Python logging in distributed systems?▼

Contextvars are required for Python logging in distributed systems to manage request-scoped data across async boundaries. This ensures context propagation correctly carries metadata like correlation IDs throughout the application stack.