- Notifications
You must be signed in to change notification settings - Fork 52
Description
Issue Description:
A new method, findBy(Specification<T> spec, Function<FluentQuery.FetchableFluentQuery<S>, R> queryFunction)
, has been introduced in the JPA (since 3.0.x) repository interface called JpaSpecificationExecutor
. This method enhances the flexibility of querying by allowing users to define custom queries using specifications and fluent query APIs. However, as of the current version of this library (3.0.1), this method has not been exposed for use by developers.
Expected Behavior:
A new method findBy(Specification<T> spec, Function<FluentQuery.FetchableFluentQuery<S>, R> queryFunction, EntityGraph entityGraph)
should be made accessible in the EntityGraphJpaSpecificationExecutor
interface, thus enabling developers to leverage its capabilities to create more tailored and efficient queries when working with JPA repositories.
Steps to Reproduce:
Since the method is not exposed, there is currently no way to directly demonstrate the issue. However, it can be confirmed by examining the EntityGraphJpaSpecificationExecutor
interface and comparing its methods with the available ones in the JPA interface JpaSpecificationExecutor
.
Impact:
The absence of this method limits the query customization options available to developers when utilizing JPA repositories. By exposing this method, developers can take advantage of the advancements in query flexibility introduced in JPA 3.0.x and beyond.
Additional Information:
- Library Version: 3.0.1
- JPA Version: 3.0.x
- Relevant Documentation: JPA method
findBy(Specification<T> spec, Function<FluentQuery.FetchableFluentQuery<S>, R> queryFunction, EntityGraph entityGraph)
Proposed Solution:
Expose the new method findBy(Specification<T> spec, Function<FluentQuery.FetchableFluentQuery<S>, R> queryFunction, EntityGraph entityGraph)
in the EntityGraphJpaSpecificationExecutor
interface so that developers can utilize it for creating custom queries with specifications and fluent query APIs.