logging-observability

Configure structured JSON logging, Micrometer metrics, and actuator health endpoints for Spring Boot applications.

Updated Feb 7, 2026
One-click install
npx skills add https://github.com/gazolla/gazapps-java-skills --skill logging-observability-gazolla
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: logging-observability
Source: https://github.com/gazolla/gazapps-java-skills/tree/main/logging-observability
Command: npx skills add https://github.com/gazolla/gazapps-java-skills --skill logging-observability-gazolla

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Production-grade logging, metrics, and health monitoring for Spring Boot applications, enabling structured logs, request tracing, and observable performance improvements.

Core Features & Use Cases

  • Structured JSON logging with MDC-based correlation IDs and a logback encoder for production-grade log output.
  • Micrometer metrics & Actuator integration for health, metrics, and observability endpoints across services.
  • Request tracing & correlation across microservices to simplify debugging and performance analysis.

Quick Start

Configure Spring Boot to enable logging, metrics, and actuator endpoints, then run the application to observe structured logs and health information.

Frequently Asked Questions about logging-observability

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

FAQPage Schema
How do I configure structured JSON logging in Spring Boot?

You enable structured JSON logging in Spring Boot by configuring a logback encoder to format log output, enabling production-grade parsing and aggregation. This approach replaces standard logging with structured JSON output for better observability.

How does MDC-based tracing work for microservices?

MDC-based tracing works by injecting correlation IDs into the diagnostic context of each request, passing them across microservices. This simplifies debugging by linking distributed log entries to specific request flows.

What is the best way to add health checks and metrics to Spring Boot actuator?

The best way to add health checks and metrics is by integrating Micrometer with Spring Boot actuator. This combination exposes health, metrics, and observability endpoints across services for production monitoring.

Can I use Micrometer and SLF4J together for Spring observability?

You can use Micrometer and SLF4J together for Spring observability by combining metrics collection with structured logging. SLF4J handles the log output while Micrometer provides the actuator metrics integration.

When do I need structured logs and correlation IDs in Spring Boot?

You need structured logs and correlation IDs when debugging and analyzing performance across Spring Boot microservices. They provide observable performance improvements by linking distributed request flows.