Flexible Constructor Bodies in Java 25

Flexible constructor bodies in Java 25: validate arguments, prepare values and set fields before super() or this(), and learn what the prologue forbids.

Testing LLM Responses with Spring AI : LLM-as-a-judge

During unit testing of an e-commerce application, we can easily test a method that calculates an order count by comparing the test result with the expected number. But what if an LLM explains that count? “Three orders went to Pune” and “Pune received three orders” are both correct, even though …

Create a Custom Spring Boot Starter

Build a custom Spring Boot 4 starter with conditional auto-configuration, configuration properties, a consuming app, and tests for defaults and bean overrides.

Spring AI 1.x to 2.0 Migration Guide

Spring AI 2.0 migration guide: upgrade a Spring AI 1.x app to 2.0.1 step by step, with the build errors you will see and the fix for each one.

Spring Boot and Vaadin CRUD Example

Build a Spring Boot and Vaadin CRUD app with a Grid, a validated form and Spring Data JPA. Complete code for every file, run steps and real screenshots.

About Us

HowToDoInJava provides tutorials and how-to guides on Java and related technologies.

It also shares the best practices, algorithms & solutions and frequently asked interview questions.