Best of FaunOctober 2024

  1. 1
    Article
    Avatar of faunFaun·2y

    Clean Code in Practice: How I Learned to Write Maintainable Code

    Learn how embracing Clean Code principles can transform your code from chaotic and unreadable to maintainable and clear. By using meaningful names, following guidelines like PEP 8 in Python, leveraging types in TypeScript, breaking functions into smaller pieces, avoiding magic numbers, and adhering to the DRY principle, you can significantly improve the readability and maintainability of your code.

  2. 2
    Article
    Avatar of faunFaun·2y

    Java 23, SpringBoot 3.3.4, Jakarta 10

    A rapid-start template optimized for microservices and cloud-native architectures using Java 23, SpringBoot 3.3.4, and Jakarta 10. It features a packaging structure based on Hexagonal Architecture, cross-cutting concerns handled via AOP, JWT for authentication and authorization, robust web security, and Docker containerization. The Hexagonal Architecture ensures a clear separation of concerns, maintaining flexibility and adaptability. Comprehensive logging, multiple Spring profiles, and extensive use of Swagger and OpenAPI for API documentation are also highlighted.

  3. 3
    Article
    Avatar of faunFaun·2y

    Learning Go by Instrumenting a Go Application for Prometheus Metrics

    A beginner's guide to learning Go by instrumenting a Go application for Prometheus metrics. This tutorial covers building a Prometheus metrics exporter to consolidate analytics and metrics from Datadog's SLO product. Key steps include parsing the Datadog API response, creating necessary structs in Go, declaring Prometheus metrics, initializing the Datadog client, fetching SLO data, and pushing the metrics to Prometheus.

  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.