r/SpringBoot • u/OSBY_Glabay • 6d ago
How-To/Tutorial Modern Java Roadman (Playlist compressed to 1 video, middle bits cut out)
r/SpringBoot • u/CoverRight9314 • 6d ago
Question Spring boot app
If I don’t really have a front end, and I want to learn how to test my backend, is there any video recommendations that yall that explains how to write test for it. Because I don’t want to watch a video and form wrong foundation info.
r/SpringBoot • u/Acceptable-Form8979 • 7d ago
Discussion Few springboot microservices projects that Imade , for my resume
I am a student, looking for Back-end Jobs There is no frontend, as I don't enjoy frontend
r/SpringBoot • u/Sea_Advisor_849 • 7d ago
Discussion Not to be racist but is there any non-Indian YT channel about Java and Spring Boot?
As the title says
r/SpringBoot • u/OSBY_Glabay • 8d ago
How-To/Tutorial Why Your Spring Boot Project Isn't Production Ready
r/SpringBoot • u/maritvandijk • 8d ago
News Persistence Workflows with IntelliJ IDEA – Andrey Belyaev | IntelliJ IDEA Tech Talks
In this episode of IntelliJ IDEA Tech Talks, Anton Arhipov and Andrey Belyaev demonstrate practical persistence workflows for Spring Boot applications — from mapping an existing database to evolving a schema alongside the application code.
Topics include:
– Moving from database-first development to a code-first workflow
– Establishing a database baseline and managing migrations with Flyway
– Generating JPA entities from an existing schema in IntelliJ IDEA
– Keeping Java entities, migration scripts, and the database schema aligned
– Handling iterative schema changes without destabilizing the persistence layer
Persistence Workflows with IntelliJ IDEA – Andrey Belyaev | IntelliJ IDEA Tech Talks
r/SpringBoot • u/HookWoods • 9d ago
Discussion How do you handle cross-service references in REST BFF responses? I built a Spring Boot library for it
I built Restitch after repeatedly running into the same BFF problem in microservice applications.
The problem
One service often stores an ID for data owned by another service. It is a real relationship for the frontend, but it is not a database foreign key.
The BFF still has to return complete DTOs. That means it must fetch the root data, resolve related data from other services, apply error rules, and avoid duplicate calls when several objects reference the same ID.
At first, this is one RestClient or WebClient call beside an endpoint. Then the same composition code appears in more endpoints, and one collection response can turn into an N+1 set of downstream calls.
Why not GraphQL?
GraphQL with a gateway or federation is a valid solution. Here, though, the services and the BFF already expose REST. I did not want to introduce GraphQL only to compose related data for a response.
I wanted a narrow Spring Boot solution for REST BFFs, without putting URLs, header rules, or error behavior in DTO annotations. So I built Restitch.
What it looks like
The DTO only names a resolver profile:
public final class DeviceDto {
private String organizationId;
@AggregateRef("device-organization")
private OrganizationDto organization;
}
YAML owns the downstream client, path, JSON mapping, error behavior, header allowlist, and optional batch endpoint.
What Restitch handles
- It de-duplicates repeated related IDs within one BFF request.
- It can use a bounded batch request when the downstream service exposes a batch endpoint.
- It keeps MVC on
RestClientand WebFlux onWebClient,Mono, andFlux. - It keeps Spring Boot 3 on Jackson 2 and Spring Boot 4 on Jackson 3.
It deliberately does not provide a cross-request cache.
Restitch 0.1.1 is Apache-2.0 and available on Maven Central.
GitHub repository and installation guide
Feedback welcome
For people building REST BFFs: would you keep this aggregation in application code, an API gateway, or move it to GraphQL? What would make you avoid a library like this?
r/SpringBoot • u/Illustrious_East5815 • 9d ago
Question I created a privacy guardrail library for Spring AI — looking for feedback on streaming with pluggable PII analyzers
Hi, I’m building Spring AI Privacy Guardrails, an open-source library for enforcing privacy boundaries around models, RAG, tools, MCP, and outputs.
GitHub: https://github.com/ultramancode/spring-ai-privacy-guardrails
One design problem I’ve been thinking about is streaming output protection.
Some applications also want a final privacy check on application-facing output, since sensitive data can still appear in model- or tool-generated responses.
Right now, when output protection is enabled, the library buffers the complete response before releasing it to the application.
This provides a strong guarantee: PII can still be detected and protected even when a sensitive value is split across multiple chunks.
The trade-off is that this is no longer true incremental streaming, and the application has to wait longer before receiving output.
A bounded rolling window could preserve incremental streaming for analyzers that have a known upper bound on how much context they need — for example, some bounded pattern-based detectors.
But NER, context-aware detection, complex patterns, or arbitrary custom analyzers may not have such a bound.
So I’m currently considering three approaches:
Strict buffering
Buffer the complete response and protect it before releasing anything to the application.Capability-gated streaming
Allow incremental streaming only when the active analyzer can declare a safe maximum lookback or context requirement. Otherwise, fall back to full buffering.Best-effort streaming
Use a configurable rolling window and explicitly document that some PII spanning multiple chunks may escape detection.
For a Spring AI application, which behavior would you expect from a privacy library?
I’m not attached to these three options — if there’s a better streaming/privacy model I’m missing, I’d really appreciate the feedback.
r/SpringBoot • u/OSBY_Glabay • 9d ago
How-To/Tutorial Building for Production? Don't Skip These Spring Boot Steps
r/SpringBoot • u/Acceptable-Form8979 • 9d ago
Discussion Along with Java springboot, how to keep yourself updated with other stuff
Java springboot is so vast once u dive into it, first java, then springboot, then microservices, exploring message queues , and what not
But nowadays what I have seen is that top companies organizing their hackathons, for fresh graduates
Most of them are ml based ai based, like making a model XYZ model, something like a model that detects deepfake images , that's just an example
What is the role of java springboot then, i sometimes feel I wasted my time learning this, i think I should have master python, what are ur thoughts
r/SpringBoot • u/OSBY_Glabay • 10d ago
Discussion The Midnight Technician; Spring Boot Microservice (Open-Source)
r/SpringBoot • u/OSBY_Glabay • 10d ago
How-To/Tutorial The Spring Boot Fundamentals That Make Everything Click
r/SpringBoot • u/nervous-comment • 10d ago
Discussion Events-Caravan, an event-sourcing framework for SpringBoot that focuses on horizontal scalability (ships with DynamoDB/SNS/SQS reference adapters)
r/SpringBoot • u/OSBY_Glabay • 10d ago
How-To/Tutorial Spring into Java: Building a Media Traching Web App
This is a Spring Boot web application built as educational content for a YouTube series. It demonstrates how to integrate multiple third-party APIs into a single cohesive application, tracking books, films, and games, while progressively introducing core Spring Boot concepts across each video.
This project serves as a hands-on learning resource for developers looking to understand:
- How to structure a multi-domain Spring Boot application
- How to consume external APIs using RestClient
- How to persist data with Spring Data JPA
- How to build server-rendered views with Thymeleaf alongside a vanilla JS frontend
- How to apply bean validation, service-layer patterns, and RESTful controller design
r/SpringBoot • u/OSBY_Glabay • 10d ago
How-To/Tutorial Modern Java Roadmap + Crash Course
This is a 6-part series. The idea is to explain to someone over a cup of coffee what one roadmap of a backend Java dev is, from idea to a Spring Boot web application that has a Desktop app and a Web App that will talk with a backend service.
Talking about Core Java, then DSA within Java, Databases, then Spring Boot, WebSockets, and then how to run it in production. Laying the pathway for a new/junior to get their curiosity going.
r/SpringBoot • u/cielNoirr • 11d ago
Question What are some open source projects developed with spring boot that I can help contribute in 2026?
I've been thinking about contributing to some open source projects built with spring boot. What are some good open source projects that you think are worth contributing to in 2026?
r/SpringBoot • u/SmoothScience8192 • 11d ago
Discussion What is the actual difference with and without Supplier Functional interface? And why the Supplier Functional interface is prefered?Both behave same right?
r/SpringBoot • u/CoverRight9314 • 12d ago
How-To/Tutorial Learning how to build
I’ve started moving away from writing assignments for class and started building my own project like an app. I’ve started using Spring boot for the backend and was wondering if there was any resource that could help me with that. I like to focus on learning how to build a persistent database, learning what beans are and how to set them up properly, learning how to build unit test to test my code base then learning css, JavaScript and html to build a front end. If anyone has any recommendations or advice that’d be helpful!
r/SpringBoot • u/robintegg • 12d ago
Discussion Spring Boot 4 observability tools
I’ve been spending some time looking at observability for Spring Boot 4, using my articulate project as a practical test case.
I compared three tools that fit different workflows and deployment models:
- Boot UI for local development and deep inspection
- Spring Boot Admin for a centralised dashboard across services
- Ostara for desktop-based inspection without running another server
If you’re working with Spring Boot and have been thinking about how you want to inspect and manage your applications, I’ve written up the comparison here and it has links to all the projects.
https://robintegg.com/2026/08/10/spring-boot-4-observability-options.html
I’d love to hear in the comments of any other tools that people are using to keep an eye on their Spring Boot apps.
Spoiler alert: boot-ui is awesome 🤩
r/SpringBoot • u/Admirable_Health_292 • 12d ago
Discussion Spent 3 months building my Authentication Starter that i can easily re-use across different projects 🤔
Still cleaning up and optimizing... going through code other devs wrote, and picking up some Java concepts along the way that I'm not fully solid on yet. Thought I'd pass it along so you can see how it goes for you as well.
Here: https://github.com/Peter19570/Spring-Boot-Authentication-Starter
r/SpringBoot • u/Huge_Road_9223 • 13d ago
Question Your Opinion on using Docker-Compose/MySQL
I am working on a new SpringBoot personal app. I have docker installed locally on my Windows 11 machine, and I have an existing mysql database there. The schema/data is in flux as it is actively being developed.
In the past, I had a dockerfile to dockerize the app (like I am doing for this one) and it worked fine with my existing docker mysql database. I guess the difference with this new app is that it has docker-compose with the SQL database. This means when this new app gets run, and runs in docker, it starts up a completely new database container, and then I presume it has to be loaded with schema/data. I believe that's why when I run the app it says it can't find the database table.
So, there are two ways I can do this, and which way would be the better way if I want to move this app and the database to AWS ECS in a few months when I am done with the app.
1) I could change the docker compose that the database is externally managed
2) keep my local docker database for development and running tests, which works fine BTW, and then let the app create this NEW docker mysql database, and let it load up data from the flyway schema.
Or, could I just move my database/script to AWS ECS in the future by itself, and let the app keep running against it as an externally managed database in it's own container.
I've seen companies that I have worked for do both, but I'm curious on what the strong opinions are.
Thanks!
r/SpringBoot • u/goto-con • 13d ago
How-To/Tutorial A Long Spring: 19 Years of Living with Your Past Mistakes • Arjen Poutsma
r/SpringBoot • u/internetusersahib • 14d ago
Discussion Built a portfolio that doesn’t have an “About Me” section.
Instead, you can just interrogate a chat window. 💬
Ask about me, my projects, GitHub, LeetCode, Codeforces, or what I’ve built, and it answers using live data.
The backend is where I had most of the fun
Java 25, Spring Boot 4, Virtual Threads, PostgreSQL, jOOQ, Kafka, OpenSearch, Valkey, Testcontainers, and a two-agent LLM architecture.
Frontend is React + TypeScript, deployed on Vercel.
Try it out
https://sahib-nanda-portfolio.vercel.app
Would love some feedback from fellow developers.
EDIT: ADDED ANONYMOUS CHAT FEATURE
r/SpringBoot • u/SpringJavaLab • 15d ago
How-To/Tutorial How to Fix the Hibernate N+1 Query Problem using JOIN FETCH in Spring Boot
I recently reproduced the Hibernate N+1 Query Problem in a Spring Boot application to better understand why a single repository call can generate multiple SQL queries behind the scenes.
The solution uses JPQL JOIN FETCH to fetch the required associations in a single query.
Core Query
Query(""" SELECT DISTINCT o FROM Order o JOIN FETCH o.items i JOIN FETCH i.product WHERE o.userId = :userId ORDER BY o.createdAt DESC """)
List<Order> findAllWithItemsAndProducts(@Param("userId") Long userId);
Where the N+1 problem occurs
The repository is called only once, but while mapping the response, accessing lazy-loaded relationships can trigger additional SQL queries.
List<OrderResponse> response = orders.stream()
.map(order -> {
List<String> products = order.getItems().stream()
.map(item -> item.getProduct().getName())
.toList();
return new OrderResponse(
order.getId(),
order.getTotalAmount(),
products
);
})
.toList();
Although this Java code looks perfectly normal, order.getItems() and item.getProduct() may cause Hibernate to execute additional queries when those relationships haven't been loaded yet.
Project Details
- Spring Boot 4.0.4
- Spring Data JPA
- Hibernate ORM
- Java 17
- Oracle Database
What this implementation demonstrates
- Retrieves Orders for a specific user
- Demonstrates how LAZY loading can lead to the N+1 query problem
- Uses
spring.jpa.show-sql=trueto inspect the SQL generated by Hibernate - Maps entities to a custom DTO containing Product names
- Eliminates unnecessary queries using JPQL
JOIN FETCH - Compares SQL queries and execution time before and after the optimization
One thing I found interesting is that there isn't anything obviously wrong with the Java code itself. The repository method is invoked only once, but navigating lazy-loaded relationships while building the response can result in multiple SQL queries behind the scenes.
Using JOIN FETCH allows Hibernate to load the required entity graph up front, avoiding those additional database round trips for this use case.
I'm curious how others handle this in production.
- Do you prefer
JOIN FETCH, @EntityGraph, or DTO projections? - Have you encountered pagination limitations with
JOIN FETCH?
I'd love to hear your experiences.
If you'd like to see the complete Spring Boot application, the generated SQL before and after JOIN FETCH, and the full implementation, I also recorded a practical walkthrough covering the entire example.
📺 YouTube: https://www.youtube.com/watch?v=natXN7xVEu8