9d42a42d261e4c474754acac60c165cae2fb3500
sdjpa4-demo
Runnable companion project for Spring Data JPA 3 to 4 Migration Guide on ankurm.com.
Four entities, two repositories, a @NullMarked package, seven passing behavior tests, and an A-G demo runner that prints every labelled console output shown in the article. Boots H2 in memory, so there's nothing to install beyond a JDK.
Built and verified on Eclipse Temurin JDK 21.0.11, Spring Boot 4.0.6, Spring Data JPA 4.0.6, Hibernate ORM 7.2, H2 in-memory.
Run it
git clone https://ankurm.com/git.app/asmhatre/sdjpa4-demo.git
cd sdjpa4-demo
./mvnw spring-boot:run # prints the labelled A-G demonstrations
./mvnw test # runs the 7 behavior tests (all green)
Description
Runnable Spring Boot 4.0.6 / Spring Data JPA 4.0.6 sample demonstrating the 3.x -> 4.0 migration behavior shifts (JSpecify null-handling, JPQL-derived queries, NULLS precedence, Specification API). Companion code for the ankurm.com migration guide.
Languages
Java
100%