Open barryspearce opened 1 year ago
afaik Spring Data JPA 3.X supports Specifications with Projections out-of-the-box, so there should be no need for this particular library if you're using Spring Boot 3.
afaik Spring Data JPA 3.X supports Specifications with Projections out-of-the-box, so there should be no need for this particular library if you're using Spring Boot 3.
@eidottermihi The JpaSpecificationExecutor seems not to have changed between 2 and 3. No method supporting a specification and a projection class is available as far as I can tell - its not in the docs either. https://docs.spring.io/spring-data/jpa/docs/current/api/org/springframework/data/jpa/repository/JpaSpecificationExecutor.html
Thus I think this library is still required for Spring Boot 3.
@barryspearce my bad, you are right. I was mislead by some issues, but Specifications + Projections are still unsupported in Spring Data JPA 3. Issue requesting such a feature is https://github.com/spring-projects/spring-data-jpa/issues/1524
i have created a branch called spring-3.0.4 that seems to be working, but there are failing tests, I tried pushing my branch up but I get a permission denied error. push --progress --porcelain origin refs/heads/spring-3.0.4:refs/heads/spring-3.0.4 --set-upstream remote: Permission to pramoth/specification-with-projection.git denied to mdillenk.
@mdillenk you should maybe fork first and create a PR on your fork
Thanks @mdillenk for your effort. I've created a new PR based on your changes including the fix to unit test failure. https://github.com/pramoth/specification-with-projection/pull/33
javax.persistence should be changed to jakarta.persistence to support Spring boot 3.
This does involve moving the baseline to Java 17.