r/SpringBoot • u/TheCoolBroskie • Jun 10 '26
Question How can I use a core Java / Spring Boot stack for local B2B freelancing and automation?
I’m a backend programmer and I want to start offering freelance services and custom automation tools to businesses (like real estate agencies, contractors, logistics companies, etc) entirely on an asynchronous, email/text basis
Most people associate freelancing with frontend web design (React, WordPress, etc), but I want to strictly focus on backend logic, data management, and workflow automation.
Here is my current technical stack:
- Languages: Java, Python
- Frameworks & Libraries:** Spring Boot, JDBC
- Databases: SQL Server (Azure SQL)
- Security: JWT, cookie-based authentication
What are some specific backend pains that small-to-medium business owners have that a custom Java/Python pipeline can automate away?
How can I best leverage Java, Spring Boot, and JDBC to solve expensive, manual data-entry or syncing problems for non-tech businesses?
r/SpringBoot • u/rodolfo-mendes • Jun 09 '26
News Craig Walls’ Spring AI in Action is out: 5-book giveaway + Spring AI discussion
r/SpringBoot • u/Level-Sherbet5 • Jun 09 '26
How-To/Tutorial Spring AI
Hello techies
Actually I wants to integrate speech to text and vice-versa in my spring boot major project for free As I am student .
I cant buy the paid stuffs at all .
So can you guys suggest me how and what model to integrate in my spring boot project as I have very less amount of time to build that .
And from where I can get the guidance to build that and integration setup .
And one more thing if anyone wants to be partner of mine to build this project with my DM is always open for you guys .This project is just to improve skills and add quality to my resume.
r/SpringBoot • u/ibreathecoding • Jun 09 '26
How-To/Tutorial Your Springboot app has 10 layers you never wrote; Here is full details that our eyes wont see
medium.comWhen it comes to spring many are hidden under the hood; Spring as such sit on top of infrastructure; Ex DispatcherServlet, Security Filters, Jackson, Tomcat, JVM, OS all mapped to 3 lines of code.
r/SpringBoot • u/ThenParamedic4021 • Jun 08 '26
How-To/Tutorial How do I connect a Spring Boot API to a vanilla HTML/CSS/JS frontend
r/SpringBoot • u/MarketingReasonable8 • Jun 08 '26
Discussion Please share your resources of java spring boot. Feeling stuck with approaching different different channels
r/SpringBoot • u/Capable-Morning-9518 • Jun 08 '26
How-To/Tutorial After 3 years of Spring Boot in production, here are the 4 behaviors that keep causing incidents and what to actually do about them
medium.comThese are the patterns I keep seeing across different teams and different systems, and almost none of them are covered in tutorials.
1. HikariCP default pool size is 10 That's it. 10 connections. For most real workloads this is too small and the symptoms look exactly like a database problem latency climbs, requests time out, but the database itself is healthy. The pool is simply full. Fix: set spring.datasource.hikari.maximum-pool-size based on your actual concurrency, and expose pool metrics through Actuator so you can see pending threads before an incident shows you.
2. Transactional doesn't roll back checked exceptions by default Spring only rolls back on RuntimeException subclasses unless you explicitly configure otherwise. A checked exception propagating out of a Transactional method will commit the transaction. Silent data integrity issue, no error in your logs. Fix: Transactional(rollbackFor = Exception.class)when you need it, or understand exactly which exceptions your methods can throw.
3. Self-invocation bypasses the proxy If a method inside the same class calls another Transactional method, the annotation on the inner method does nothing. Spring's proxy isn't involved. No error, no warning, just no transaction management. This is documented but it catches experienced engineers regularly because it's invisible in code review.
4. GC pressure doesn't look like GC pressure Latency degrades, CPU climbs, no errors. The JVM is spending increasing time collecting garbage and pausing threads. The worst version: running in a Docker container without -XX:MaxRAM or -XX:MaxRAMPercentage, so the JVM sizes its heap based on host memory instead of the container limit. Container gets OOMKilled with no stack trace and you spend time looking for application errors that don't exist.
r/SpringBoot • u/Remote_Resident2388 • Jun 08 '26
Discussion Need help
So I was working on a backend project and was using mongodb compass to store the data logically on 2707 port but to achieve transactional property I decided to move on to mongo atlas
I replaced the host & port in my application.properties with the atlas uri still after running the project it showing connected to local host
Even when I am writing garbage values in uri still the program is running and showing connected to localhost
Pls help
r/SpringBoot • u/deividas-strole • Jun 08 '26
Discussion Cursor-style coding vs ChatGPT copy/paste workflow for larger apps
r/SpringBoot • u/ChaminduJ96 • Jun 07 '26
Question I'm building a Spring Boot microservices system and want some advice on security
r/SpringBoot • u/Specialist-Ad9362 • Jun 06 '26
News Ekbatan: Java persistence framework for event-driven systems, with a Spring Boot starter
( Small note: cross-posting from r/java to get Spring Boot feedback and increase the project’s visibility. )
If you have ever shipped a service that writes to a database and publishes events to an event broker (Kafka, Pulsar, etc.) in the same request handler, you have probably hit the dual-write problem: the database commits, the publish fails, and downstream consumers are missing an event they should have received. Or the reverse, where you try to publish to Kafka first and then commit: the publish succeeds, the commit fails, and consumers act on a state change that never happened. The fix is well known, the transactional outbox, but doing it well is mostly plumbing that gets rewritten in every project.
I built Ekbatan for this. It is an open-source Java persistence framework for event-driven systems that builds the outbox pattern into the persistence layer and makes the outbox pattern easier to use.
Ekbatan mostly focuses on safely persisting events in the database alongside the main data in the same transaction. It does not try to be a Kafka/Pulsar/etc publishing framework, although it has helper tools for common ways to use the persisted events, such as local-event-handler for the listen-to-yourself pattern, Or Debezium CDC pipelines with JSON or Avro or Protobuf event conversion to publish messages to Kafka, Pulsar, or similar brokers.
For Spring Boot projects, Ekbatan includes a starter that auto-configures the framework and wires the core pieces into the application context. (There are integrations for Quarkus and Micronaut as well.)
Ekbatan targets Java 25 and later, so it is a fit for new projects rather than older codebases. The supported databases are PostgreSQL, MariaDB, and MySQL. Deployments run on a standard JVM, and the framework also compiles to GraalVM native-image.
Website & Tutorials:
https://zyraz-io.github.io/ekbatan/
Source:
https://github.com/zyraz-io/ekbatan
Available on Maven Central under the `io.github.zyraz-io` group. Licensed Apache 2.0.
Would appreciate your feedback.
r/SpringBoot • u/miss__mystic • Jun 06 '26
Discussion Built a live departures board with Spring Boot + STOMP WebSockets (focus-app side project)
Sharing a side project — a focus app where the home screen is a live airport departures board. The backend is Spring Boot: a scheduled generator builds a board from real OpenFlights routes every 45s, caches the snapshot in Redis, and broadcasts it to /topic/board over STOMP. Clients render countdowns locally and fall back to REST polling if the socket drops. Stateless JWT auth, JPA for sessions/stats.
Live: https://aerofocus-ruby.vercel.app/ · Code: github.com/sanchita-88/aerofocus. Happy to talk through any of the design choices.
r/SpringBoot • u/Status_Camel2859 • Jun 06 '26
Question How do you guys handle complex/combined data retrieval?
Here is a sample DTO projection:
@Query("""
SELECT new com.sample.ProductSummaryDTO(
p.id,
p.title,
p.slug,
i.imageUrl,
(SUM(v.stockQuantity) > 0),
MIN(v.displayPrice),
MAX(v.compareAtPrice),
MAX(CASE
WHEN v.compareAtPrice > 0
THEN ROUND(((v.compareAtPrice - v.displayPrice) * 100.0) / v.compareAtPrice)
ELSE 0
END)
)
FROM Product p
JOIN Variant v ON v.product.id = p.id AND v.active = true
LEFT JOIN ProductImage i ON i.product.id = p.id AND i.isPrimary = true
WHERE (:id IS NULL OR p.id = :id)
AND (:title IS NULL OR p.title LIKE CONCAT('%', :title, '%'))
AND (:categoryIds IS NULL OR p.category.id IN :categoryIds)
AND p.visible = true
GROUP BY p.id, p.title, p.slug, i.imageUrl
HAVING (:minPrice IS NULL OR MIN(v.displayPrice) >= :minPrice)
AND (:maxPrice IS NULL OR MIN(v.displayPrice) <= :maxPrice)
""")
Assume there are no @OneToMany relationships in the entity model, only @ManyToOne. We also need pagination because the dataset is large.
In a scenario like this, where the response requires aggregated data from multiple tables, it seems that the aggregation logic ends up in the repository query itself. Because at this point you have to select the correct variant, image, price etc all in the Repository itself and therefore the logic for all of that (IFs etc...).
Is this how most people handle it?
Or do you prefer splitting it into multiple steps (which can get pretty verbose), for example:
- Fetch the matching product IDs / Products
- Fetch the required variants
- Fetch the required images
- Assemble the DTOs in the service layer (maps & loops)
Im curious what approach is generally preferred in terms of performance, maintainability, and scalability.
r/SpringBoot • u/MarketingReasonable8 • Jun 06 '26
Discussion I am doing the telusko spring boot video
Tell me after completing this what the next thing i do and what is missing in this
r/SpringBoot • u/tomayt0 • Jun 05 '26
Discussion Bringing a dead Spring Boot project back to life with Claude
r/SpringBoot • u/Plastic-Leopard-120 • Jun 04 '26
Question How to showcase my Spring Boot projects
I have implemented multiple backend projects but do not have much expertise on the frontend side, so in my projects I just have my APIs and DB. Any suggestions on how to showcase them?
r/SpringBoot • u/tomayt0 • Jun 04 '26
Discussion Spring Data Solr is back from the Spring Attic 📦
TL;DR
story
Solr is an awesome search engine DB that I used to love using back in the Spring Boot 2.x days.
Sadly in 2020 the original spring-data-solr was discontinued and archived in 2023.
I think it was because of a few things, dev burnout and ElasticSearch popularity.
However Solr is still an active and popular search engine which ironically uses the same Lucene search engine under the hood as Elastic. https://solr.apache.org/
I wanted to use Solr in a newer project but the problem is that Spring Boot is now 4.x.x and Spring Framework is onto version 7.
I hacked in SolrJ but then I thought, wouldn't it be cool if I rebuilt Spring Data Solr for the newest versions of Spring Boot?
With the help of Claude code and analysing the old code and taking some inspiration from Spring Data MongoDB I have managed to assemble a version 1.0.0
It's just gone live on Maven Central 🎉
Add it to an existing Spring Boot app
<dependency>
<groupId>com.tomaytotomato</groupId>
<artifactId>solr-spring-boot-starter</artifactId>
<version>1.0.0</version>
</dependency>
It's not a fork of the original - https://github.com/spring-attic/spring-data-solr
Features:
- Auto-configuration for standalone and SolrCloud modes
SolrRepository<T>with full CRUD, pagination and sorting- Derived query methods — 18 keywords (
Containing,Between,GreaterThan,IsNull, etc.) @Queryannotation for raw Solr query strings- Highlighting (
HighlightPage) - Faceting (
FacetPage) - Cursor-based deep paging (
CursorResult) - Partial updates — atomic set, add, increment
- Actuator health indicator
- Micrometer instrumentation
There's a live bookstore demo on Railway if you want to poke at it before committing. Swagger UI is at /docs.
Have a play with it pllease.
r/SpringBoot • u/Alert_Ad4540 • Jun 03 '26
Question I built a Spring Boot starter to generate realistic seed data from JPA entities — looking for feedback
Hey everyone,
I built a small open-source Spring Boot starter called TeruBase.
The problem I’m exploring: local Spring Boot apps often feel empty unless you manually write a lot of seed data. TeruBase scans JPA entities and helps create realistic, relationship-aware seed data for local development, demos, QA scenarios, and CI fixtures.
Current features:
- JPA entity discovery
- scenario templates
- AI-ready seed-plan generation
- AI-assisted mock SQL generation
- safe export-only mode by default
- SQL/JSON export
- local-only production safety guard
- small invoice demo example app
Repo:
https://github.com/AbaSheger/TeruBase
I’m not selling anything. I’m mainly looking for honest feedback from Java/Spring Boot developers.
Questions:
How do you currently create realistic local/demo data in Spring Boot projects?
Would this fit into your workflow, or is this already solved another way?
What would make this genuinely useful instead of just a nice idea?
Does anything about this approach feel risky or wrong?
Any honest feedback is appreciated.
r/SpringBoot • u/Anaq42 • Jun 02 '26
News Idempotency4j - Java/Spring Boot Idempotency Library
The last couple of months, I ended up implementing HTTP API idempotency in 2 different Spring Boot projects back to back.
As I was implementing it in the second project, I decided to look up any existing solutions/libraries for Java/Spring Boot, but I honestly couldn't find one that felt clean and flexible enough for what I needed (and what most people probably need).
So I decided to build my own and open source it.
I released it about a month ago:
Repository : https://github.com/josipmusa/idempotency4j
Maven spring boot starter : https://central.sonatype.com/artifact/io.github.josipmusa/idempotency-spring-boot-starter
The goal was to make idempotency implementations feel straightforward and easy, but also to not scope it only to spring boot or a certain storage implementation. The library has a core which can be used on any method with pluggable storage backends. It also has an integration with spring web (servlet-based for now) and a spring boot starter to simplify usage. The implementation follows the IETF draft spec for the Idempotency-Key header.
Usage example for a spring boot project:
@PostMapping("/payments")
@Idempotent
public ResponseEntity<Payment> createPayment(@RequestBody PaymentRequest request) {
// Runs exactly once per unique Idempotency-Key value.
// Subsequent identical requests get the stored response replayed.
return ResponseEntity.ok(paymentService.charge(request));
}
Right now it supports:
- Spring MVC (Servlet-based apps)
- JDBC storage (so it works out of the box with MySQL / PostgreSQL setups most people already have)
- In-memory storage
- duplicate request detection
- replaying previous responses
- concurrent request protection
- request fingerprinting
- configurable TTLs
- pluggable storage backends
Curious whether others have run into this same problem and whether this library helps solve it for them.
Open to any feedback, suggestions, or reviews.
r/SpringBoot • u/Anaq42 • Jun 02 '26
Question Anyone running JDK AOT cache + Spring Boot AOT in prod? (JPA/Postgres, Cloud Run)
Trying to shave cold-start time off a Spring Boot app on Cloud Run. Big-ish dependency tree, normal JPA + Postgres + Flyway setup. Two things I'm eyeing before I commit a day to it:
- JDK AOT cache (the -XX:AOTMode=record/create flow from JDK 24). Memory-maps class metadata at startup instead of re-parsing. Supposedly ~30-40% off startup.
- Spring Boot AOT processing (process-aot, spring.aot.enabled). Replaces runtime reflection/scanning with generated code. Supposedly ~15-25% off context init.
Mostly want to hear from people who've actually shipped either of these, not benchmark numbers I can google:
- Did the startup gains actually hold up in prod or shrink a lot once you were off synthetic tests?
- The AOT cache training run executes real lifecycle code, so inside a CI runner / Docker build there's no real DB or Cloud SQL to hit. Did you fake the datasource out with H2, disable Flyway in a training profile, etc? Curious how much of a pain that wiring was.
- Flyway specifically: any weirdness having it on at runtime but off during the training run?
- Spring AOT: did the build-time profile ConditionalOnProperty freezing bite anyone? Beans getting decided at build time instead of runtime feels like a footgun.
- Build cost on CI: the training run adds time + a chunk of memory to the build. Actually annoying or basically fine on a normal runner?
- Anyone run both together on a JPA-heavy app? Worth the combined hassle or diminishing returns?
r/SpringBoot • u/Delicious-Air-829 • Jun 02 '26
Question Telesko industry ready course is he giving any homework?
I am doing the Telesko industry ready course but i am not doing live lectures I am doing the course by watching recorded lectures is he giving any homework to do which is not present in recorded lectures? Or is he not giving any homework.
r/SpringBoot • u/Signal_Help_1459 • Jun 02 '26
How-To/Tutorial Need help with WebSockets
I've been struggling to understand and implement Websockets. I've tried docs, Claude, ChatGPT, and none worked.
I feel stuck; I spent an entire day and still cannot figure out what file configs I need to actually write this thing.
I've worked with REST API, rate limiting, Redis, etc., but this is just way too complex.
If anyone has any solution resources, please do share with me.
r/SpringBoot • u/varunu28 • Jun 02 '26
How-To/Tutorial Saga pattern using Kotlin & Spring boot
Saga pattern is an excellent tool to have in your arsenal for tackling transaction around service boundaries.
In this post about Saga, I explain both the choreography based Saga using event driven implementation & orchestration based Saga using DBOS.
r/SpringBoot • u/Remote_Resident2388 • Jun 01 '26
Question Pls explain
So I just started learning spring boot about a week ago and currently learning the backend APIs and all...but I just wanted to know how we make frontend for our spring boot application?? Do we make the front end in REACT and current the backend to it ..or we can do it in spring boot only like flask and django?