Receive daily AI-curated summaries of engineering articles from top tech companies worldwide.
Endigest AI Core Summary
Spring Data 2026.0.0-M1 introduces first-class support for type-safe property references, replacing fragile string-based property access.
•String-based property references (e.g., Sort.by("firstName")) are not validated by the compiler, causing runtime failures after refactoring
•Existing metamodel approaches like Querydsl and JPA Criteria API provide compile-time safety but require build-time code generation and additional dependencies
•The new API uses Java method references: Sort.by(Person::getFirstName, Person::getLastName), validated at compile time with full IDE refactoring support
•Nested property paths are supported via PropertyPath.of(Person::getAddress).then(Address::getCountry), each step type-checked
•Kotlin support uses the div operator for path navigation: Sort.by(Person::address / Address::city)
•Existing string-based APIs remain fully supported; type-safe paths are strictly additive and can be adopted incrementally
This summary was automatically generated by AI based on the original article and may not be fully accurate.