Best of LoggingOctober 2024

  1. 1
    Article
    Avatar of communityCommunity Picks·2y

    5 Tips for Structured Logging in Spring Boot 3.4

    Spring Boot 3.4 introduces native support for structured logging using formats like Elastic Common Schema (ECS) and Logstash. This reduces dependency management and enhances observability in applications by capturing logs in a structured manner. The post emphasizes the importance of logs in understanding application behavior, particularly in distributed systems, and highlights best practices for logging. It also underscores the role of tools like OpenTelemetry and Digma in achieving comprehensive observability.

  2. 2
    Video
    Avatar of mattpocockMatt Pocock·2y

    Going weirdly deep on console.log

    Discover ways to enhance console logging in Node.js. Learn how to use util.inspect for detailed object inspection, including setting the depth and adding colors. Understand how console.dir can achieve similar results without importing util.

  3. 3
    Video
    Avatar of kantancodingKantan Coding·2y

    Linus's Laws of Writing Readable Code

    Choosing indents wisely can significantly impact code readability, with an optimal eight-character tab indentation. Long lines of code should be split carefully, avoiding breaks in user-visible strings or log messages. The complexity and indentation levels of a function determine its maximum permissible length, and clear code should negate the need for detailed comments explaining its function.

  4. 4
    Article
    Avatar of faunFaun·2y

    Java 23, SpringBoot 3.3.4: Logback Setup— Part 3

    This post provides a detailed guide on setting up Logback in a Spring Boot application, focusing on best practices for logging, including managing log levels, avoiding sensitive data leaks, using rolling file appenders, enabling asynchronous logging, and externalizing logging configurations. It also discusses the integration of logging properties in application properties, and configuring rolling policies based on size and time. The post outlines how to implement meaningful log messages, use MDC for contextual information, and leverage structured logging for better log aggregation and monitoring.

  5. 5
    Article
    Avatar of baeldungBaeldung·2y

    Monitor Java Application Logs With Loggly

    This tutorial walks through configuring SolarWinds Loggly, a cloud-based log management tool, for Java applications using various logging libraries like Log4j and Logback. It demonstrates setting up accounts, configuring systems for log transport, and verifying the setup to enable efficient log monitoring and analysis.