Best of Spring Framework2024

  1. 1
    Article
    Avatar of devgeniusDev Genius·2y

    GitHub Actions Step-by-Step Guide

    Learn how to deploy a Java Spring Boot application using GitHub Actions. This guide covers setting up a GitHub Actions workflow to build, test, and deploy the application to Docker Hub. The steps include creating a Maven project, configuring the YAML workflow file, and using Docker Hub for deployment. Securely manage Docker credentials using GitHub secrets.

  2. 2
    Article
    Avatar of javarevisitedJavarevisited·2y

    Top 5 Websites to Learn Spring Framework in Depth

    Spring Framework is a popular tool in the Java ecosystem for building robust and scalable applications. To help learners, the post lists five websites that offer comprehensive Spring tutorials and courses: Udemy, Spring Framework Official Documentation, Baeldung, Java Brains, and Spring Framework Guru. These platforms provide resources for both beginners and advanced developers, covering topics from dependency injection to Spring Boot, AOP, and data access.

  3. 3
    Article
    Avatar of justjavaJust Java·2y

    Java & Spring Best Practices | Strategy Pattern

    The new module in the `java-spring-best-practices` repository focuses on the Strategy Pattern, detailing how to implement it in a Spring application. It emphasizes designing code that is flexible and extensible, helping developers decouple algorithm selection from the main logic. Check out the module for practical examples and contribute to the project on GitHub.

  4. 4
    Article
    Avatar of jetbrainsJetBrains·2y

    Top Java Blogs for Experienced Programmers

    A curated list of personal blogs from top Java experts, offering insights on topics like JVM performance tuning, Spring, JPA, Hibernate, and more. These blogs provide practical tips, tutorials, conference talks, and innovative solutions for building high-performance Java applications.

  5. 5
    Article
    Avatar of itnextITNEXT·2y

    CQRS — Command Query Responsibility Segregation — A Java, Spring, SpringBoot, and Axon Example

    This post introduces Command Query Responsibility Segregation (CQRS) and explains its benefits in software architecture, including its ability to handle different loads for read and write operations, manage security concerns, and maintain data consistency. It provides a practical example using Java, Spring, SpringBoot, and Axon, demonstrating how to implement CQRS with separate databases for command and query operations. Key components like commands, queries, models, EventHandlers, and CommandBus are detailed, alongside dependencies and database configuration.

  6. 6
    Article
    Avatar of javarevisitedJavarevisited·2y

    How to use @Transactional annotation like a pro

    Explores advanced usage of the @Transactional annotation in Java Spring microservices to manage concurrency and transactional integrity. Highlights include solving issues with parallel processing in distributed systems, understanding isolation levels, and optimizing transactions. Provides examples with Kafka, PostgreSQL, and Spring Data JPA along with practical tips for using @Transactional effectively.

  7. 7
    Article
    Avatar of justjavaJust Java·2y

    Java & Spring Best Practices | Factory Pattern

    The third module of the java-spring-best-practices repository introduces the Factory Pattern, a design pattern for flexible object creation. Learn how to decouple object creation, enhance scalability, and improve maintainability in your codebase. The module includes practical examples, core principles, benefits, and End-to-End tests for validation.

  8. 8
    Article
    Avatar of jetbrainsJetBrains·2y

    Java Frameworks You Must Know in 2024

    Discover popular Java frameworks like Spring, Micronaut, Hibernate, and Apache Kafka. Also explore testing frameworks like JUnit, Mockito, WireMock, Testcontainers, and Awaitility.

  9. 9
    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.

  10. 10
    Article
    Avatar of baeldungBaeldung·2y

    Changing Spring Boot Properties at Runtime

    Discover how to dynamically manage Spring Boot application configurations at runtime using various methods. Learn about creating prototype-scoped beans, utilizing Spring Cloud's @RefreshScope and /actuator/refresh endpoint, and managing external configuration files. These techniques allow for on-the-fly changes without restarting the application, providing flexibility and enhancing maintainability.

  11. 11
    Article
    Avatar of gcgitconnected·2y

    JPA vs Hibernate vs Spring Data JPA

    Comparison of Hibernate, JPA, and Spring Data JPA for data persistence in Java applications.

  12. 12
    Article
    Avatar of netflixNetflix TechBlog·2y

    Java 21 Virtual Threads - Dude, Where’s My Lock?

    Netflix engineers encountered issues with virtual threads in Java 21 causing timeouts and hung instances in their microservices running on SpringBoot 3 and embedded Tomcat. Detailed diagnostics revealed that virtual threads were waiting for reentrant locks, with OS threads pinned and unable to release, leading to a variation of deadlock. The investigation and resolution process underscores the challenges and potential of adopting virtual threads for improved performance.

  13. 13
    Article
    Avatar of javarevisitedJavarevisited·2y

    Understanding Spring Core: The Foundation of Spring Framework

    The post explores the importance of the Spring Core Module in the Spring Framework, including the concept of Spring containers and Spring beans. It discusses the role of containers in managing the lifecycle and dependencies of beans and explains why they are called IoC containers. The post also covers different types of dependency injection techniques used in Spring.

  14. 14
    Article
    Avatar of medium_jsMedium·2y

    The ultimate static file server benchmark

    The article presents a benchmark of the performance of static file servers implemented in various languages. The front-runners in terms of performance were Quarkus, Webflux, and Rust.

  15. 15
    Article
    Avatar of javarevisitedJavarevisited·2y

    Most popular Java frameworks for web development

    Java remains a popular programming language for web development due to its scalability, security, and reliability. Several frameworks like Java Server Faces (JSF), Spring, Google Web Toolkit (GWT), Hibernate, Struts, Grails, Dropwizard, Blade, and Play stand out for their unique features and capabilities. These frameworks help developers build structured, secure, and efficient applications, with some focusing on rapid development and ease of use, while others offer robust support for enterprise-level applications.

  16. 16
    Article
    Avatar of justjavaJust Java·2y

    SpringBoot – How to setup HTTPS

    Walkthrough setup of TLS/SSL in a SpringBoot REST application with a focus on making the guide concise. It offers practical steps without delving too deeply into technical details.

  17. 17
    Article
    Avatar of javarevisitedJavarevisited·2y

    Review Spring Framework

    The Spring Framework uses Inversion of Control (IOC) to manage the control flow and object dependencies through mechanisms like dependency injection. The IOC container in Spring is represented by the Application Context, which manages the lifecycle of beans. Bean Factory and Application Context are two types of IOC containers, with the latter offering extended functionalities. Spring beans have different scopes such as Singleton, Prototype, Request, Session, and Application, each serving distinct use cases. The framework also supports various annotations for configuration and dependency management, and it allows the modularization of concerns via Aspect-Oriented Programming (AOP).

  18. 18
    Article
    Avatar of javarevisitedJavarevisited·2y

    6 Tips to Avoid NullPointerException in Java

    NullPointerException is a frequent error in Java caused by accessing null references. Preventing this error improves code reliability and maintainability. Key tips include performing null checks, using the equals method correctly, leveraging the Optional class from Java 8, using String.valueOf() and Objects.requireNonNullElse() methods, and opting for primitive types when possible. Annotations and the Bean Validation API in Spring can also help ensure null checks. Implementing these strategies reduces the likelihood of NullPointerException and enhances code robustness.

  19. 19
    Article
    Avatar of hnHacker News·2y

    PostgreSQL and UUID as primary key

    UUIDs are often used as primary keys in databases due to their uniqueness and ease of generation. While not always the optimal choice due to size concerns, PostgreSQL offers a dedicated UUID type that is more efficient than storing UUIDs as text. Experiments show that using the `uuid` type significantly reduces table and index size compared to `text`. Furthermore, UUID v7, which generates time-sorted values, improves insert performance over the more common UUID v4. These optimizations are crucial for large datasets and high-traffic applications.

  20. 20
    Article
    Avatar of vladmihalceaVlad Mihalcea·2y

    A beginner’s guide to Spring Data Envers

    Spring Data Envers augments Spring Data JPA repositories by providing audit logging capabilities, allowing you to track entity changes with minimal application changes. Using annotations like @Audited, Hibernate generates audit logs for entity operations such as insert, update, and delete. Additionally, Spring Data Envers extends JPA repositories with methods to query entity revisions, facilitating audit log access and revision history tracking.

  21. 21
    Article
    Avatar of baeldungBaeldung·2y

    DDD with jMolecules

    Learn how to leverage jMolecules to express Domain-Driven Design (DDD) concepts using annotations and type-based interfaces. The post covers key DDD elements such as Value Objects, Entities, Aggregate Roots, and Repositories, and demonstrates how to use jMolecules for building a domain model of a blogging application. It also explains how to integrate jMolecules with popular Java and Spring libraries and enforce DDD principles using ArchUnit.

  22. 22
    Video
    Avatar of teluskoTelusko·2y

    Spring Boot and Spring Security with JWT

    The post discusses the Spring Framework, popular in enterprise Java applications for its scalability and security. It highlights the evolution from Java EE to Spring and introduces Spring Boot, which simplifies project setup and management. The post also mentions Spring's role in building various applications like microservices and serverless apps, emphasizing dependency injection and the ioc container. The discussion extends to auto-wiring and configuring Spring Boot via annotations for efficient object management.

  23. 23
    Article
    Avatar of communityCommunity Picks·2y

    11 Non-AI Java Trends: From GraalVM to Spring Modulith

    Java developers are showcasing interest in several non-AI trends. These include GraalVM for improving runtime efficiency, Data-Oriented Programming (DOP) for treating data as first-class citizens, the debate between Quarkus and Spring Boot, in-depth details of Spring Internals, Kotlin integration with Spring Boot, and security improvements with Spring Security 3 and OAuth2. Additionally, discussions focus on the benefits of Spring Data JDBC, alternatives to Thymeleaf templates, the evolving Spring Modulith architecture, enhanced runtime efficiency with virtual threads and CRaC in Java 21, and observability improvements introduced in Spring Boot 3.2 and 3.3.

  24. 24
    Article
    Avatar of justjavaJust Java·2y

    Java & Spring Best Practices | Dependency Injection

    New GitHub repository 'java-spring-best-practices' launched, focusing on Java and Spring best practices through practical code snippets. The first module covers Dependency Injection, highlighting constructor injection for better immutability and testability. Contributions to the repository are encouraged.

  25. 25
    Article
    Avatar of justjavaJust Java·2y

    Java Spring Boot for Beginners | Part 3 : Dependency Injection and Components

    Discover how Dependency Injection and IoC containers in Java Spring Boot can help make your code cleaner and more efficient. The tutorial provides an in-depth explanation of these concepts for beginners.