-
Notifications
You must be signed in to change notification settings - Fork 716
Spring Data 2026.1 Release Notes
Details
-
Spring Data Build - 4.2
When @Query(name = "…") or @Query(countName = "…") reference a named query that does not exist, Spring Data JPA now consistently throws a QueryCreationException at repository initialization. Absent named querties previously fell back to a derived query silently, which made typos easy to miss.
Applications using name or countName with a value that does not resolve to an existing named query will fail to start and surface the mismatch. For example, the following declaration now requires that a named query UserRepository.findByLastname.count exists:
@Query(value = "select u from User u where u.lastname = :lastname",
countName = "UserRepository.findByLastname.count")
Page<User> findByLastname(String lastname, Pageable pageable);To fix this, either register the corresponding named query or remove countName to let Spring Data JPA derive the count query automatically. The derived <name>.count convention, used when countName is not set at all, is unaffected and continues to fall back silently.
-
M1 - July 2026
-
M2 - September 2026
-
RC1 - October 2026
-
GA - November 2026
-
OSS Support until: December 2027
-
End of Life: December 2028