Commit Graph

2473 Commits

Author SHA1 Message Date
Mark Paluch
41bfd415ca Polishing.
Add fix to Update, Delete, and PredicateSpecification. Reformat code. Refine tests.

See #3849
Original pull request: #3856
2025-05-16 12:25:56 +02:00
SWQXDBA
dc854df741 Fix handling of null predicate in Specification.not().
When toPredicate() returns null, Specification.not() now returns
builder.disjunction() instead of builder.not(null). This change
ensures proper handling of null predicates in negated specifications.

Closes #3849
Original pull request: #3856

Signed-off-by: SWQXDBA <983110853@qq.com>
2025-05-16 12:25:56 +02:00
Mark Paluch
5ebfdb6566 Polishing.
Add dynamic projection benchmark.
2025-05-16 12:25:56 +02:00
Mark Paluch
403e1b4d01 Use parameter names in derived JPQL queries.
We also use improved parameter naming for keyset queries for easier correlation of values.

Closes #3857
2025-05-16 12:25:56 +02:00
Mark Paluch
ddeac0cacd After release cleanups.
See #3751
2025-05-16 12:25:55 +02:00
Mark Paluch
c57ee667bf Prepare next development iteration.
See #3751
2025-05-16 12:25:55 +02:00
Mark Paluch
68fb398b4b Release version 4.0 M2 (2025.1.0).
See #3751
2025-05-16 12:25:55 +02:00
Mark Paluch
8ac384c96e Prepare 4.0 M2 (2025.1.0).
See #3751
2025-05-16 12:25:55 +02:00
Mark Paluch
fe3c22dad0 Polishing.
Fix post-rebase conflicts.

See #3622
2025-05-16 12:25:55 +02:00
hgh1472
1781819e59 Remove unnecessary parameter.
Remove unnecessary boolean nativeQuery from checkHasNamedParameter of StringQueryUnitTests class.

Signed-off-by: hgh1472 <hgh1472@naver.com>

Closes #3827
Original pull request: #3828
2025-05-16 12:25:55 +02:00
Christoph Strobl
0e7aef080f Remove hardcoded repository fragment from test setup.
See #3830
2025-05-16 12:25:55 +02:00
Mark Paluch
fbd214f72e Polishing.
Run AotMetamodel against live EntityManagerFactory, use Environment to check for AOT repository enabled flag.

See #3830
2025-05-16 12:25:54 +02:00
Mark Paluch
eb1266888f Add support for JSON repository metadata.
See #3830
2025-05-16 12:25:54 +02:00
Mark Paluch
be4d8528b3 Add AOT repository benchmarks.
See #3830
2025-05-16 12:25:54 +02:00
Mark Paluch
d3cc7da3d9 Add support for QueryRewriter.
See #3830
2025-05-16 12:25:54 +02:00
Mark Paluch
9fe7d423ef Document AOT repositories.
See #3830
2025-05-16 12:25:54 +02:00
Mark Paluch
f2b0dca62b Add support for projections.
See #3830
2025-05-16 12:25:54 +02:00
Mark Paluch
e38b219898 Add support for Entity Graphs.
See #3830
2025-05-16 12:25:54 +02:00
Mark Paluch
4b0a83a97b Simplify package structure.
See #3830
2025-05-16 12:25:53 +02:00
Mark Paluch
22dfb1c22b Add support for Value Expressions, Stream, Named and Modifying Queries.
See #3830
2025-05-16 12:25:53 +02:00
Mark Paluch
b419041cb6 Add support for Value Expressions, Stream, Named and Modifying Queries.
See #3830
2025-05-16 12:25:53 +02:00
Mark Paluch
daae010e21 Polishing.
Fix Like with starts/ends, use proper parameter origins instead of assuming binding name matches parameter names. Simplify binding block.

See #3830
2025-05-16 12:25:53 +02:00
Mark Paluch
802a8db1d1 Add query hint support.
See #3830
2025-05-16 12:25:53 +02:00
Mark Paluch
c399ca2b54 Refactoring.
Introduce AotRepositoryFragmentSupport, adopt to FragmentCreationContext.
Reduce visibility. Refactor CodeBlocks builder. Simplify query rewriting and use base class methods.
Use typed verifier through a JDK proxy to avoid reflective frontend.
Revise testing to a plain old Spring test but testing the AOT fragment through its interface by forwarding reflective calls to the AOT fragment.
Refactor AotQuery into AotQueries to support a wider range of possible queries.

See #3830
2025-05-16 12:25:53 +02:00
Christoph Strobl
831d04dd2c Add support for AOT repositories.
Closes #3830
2025-05-16 12:25:53 +02:00
Mark Paluch
b58c423bdf Upgrade to Eclipselink 5.0.0-B07.
Closes #3837
2025-05-16 12:25:52 +02:00
Mark Paluch
be5fcb30ce Upgrade to Hibernate 7.0.0.Beta5.
Closes #3836
2025-05-16 12:25:52 +02:00
Mark Paluch
1529ec252a Apply QueryRewriter to count queries as well.
We now use QueryRewriter to post-process count queries as well. Previously, only the actual result query has been processed.

Closes #3801
2025-05-16 12:25:52 +02:00
Mark Paluch
e2446caf38 Polishing.
Introduce refined names: EntityQuery, TemplatedQuery, ParametrizedQuery, QueryProvider. Return QueryProvider where possible. Introduce rewrite as concept on DeclaredQuery to retain its nature and track the origin of the query rewriting.

Move methods solely used in tests to TestDefaultEntityQuery.

Remove unused methods, fix naming, group DeclaredQuery implementations in DeclaredQueries. Add documentation.

See #3622
Original pull request: #3527
2025-05-16 12:25:52 +02:00
Christoph Strobl
5da86f1bf0 Refactoring.
See #3622
Original pull request: #3527
2025-05-16 12:25:52 +02:00
Mark Paluch
878cd8cd4d Introduce QueryEnhancerSelector to configure which QueryEnhancerFactory to use.
Introduce QueryEnhancerSelector to EnableJpaRepositories.

Also, split DeclaredQuery into two interfaces to resolve the inner cycle of query introspection while just a value object is being created.

Introduce JpaQueryConfiguration to capture a multitude of configuration elements.

Remove `spring.data.jpa.query.native.parser` option introduced earlier with #2989

Closes #3622
Original pull request: #3527
2025-05-16 12:25:52 +02:00
Mark Paluch
047fa2bc38 Polishing.
Simplify POM setup. Reformat code.

See #3745
Original pull request: #3781
2025-05-16 12:25:51 +02:00
Christoph Strobl
59e9f3459c Add contract annotations to public API.
See #3745
Original pull request: #3781
2025-05-16 12:25:51 +02:00
Christoph Strobl
c40c90bc84 Migrate to JSpecify annotations for nullability constraints.
Closes #3745
Original pull request: #3781
2025-05-16 12:25:51 +02:00
Yanming Zhou
e90f2fea91 Polishing.
Add missing `@FunctionalInterface` to Specification interfaces.
`SpecificationUnitTests` shouldn't be `Serializable`.

Closes #3452
2025-05-16 12:25:51 +02:00
Mark Paluch
3cb7e909cb Polishing.
Refine temporal literal handling. Update documentation.

See #3172
Original pull request: #3187
2025-05-16 12:25:51 +02:00
Greg L. Turnquist
b61c51d8c4 Add visitor to build an order expression from a JPQL order specification.
We now parse JpaSort.unsafe(…) expressions using our Query Parser and translate the parsed tree into a CriteriaQuery Expression except for CAST, TREAT and subqueries.

Closes #3172
Original pull request: #3187
2025-05-16 12:25:51 +02:00
Christoph Strobl
1096088c41 After release cleanups.
See #3680
2025-05-16 12:25:51 +02:00
Christoph Strobl
dece8de686 Prepare next development iteration.
See #3680
2025-05-16 12:25:50 +02:00
Christoph Strobl
393161f863 Release version 4.0 M1 (2025.1.0).
See #3680
2025-05-16 12:25:50 +02:00
Christoph Strobl
01f3f41362 Prepare 4.0 M1 (2025.1.0).
See #3680
2025-05-16 12:25:50 +02:00
Mark Paluch
7a6cddf720 Polishing.
Add SpecificationFluentQuery to include specification-related overloads. Also, add slice(…) terminal method to obtain a slice only without running a count query.

See #3727
2025-05-16 12:25:50 +02:00
Joshua Chen
e5df40b0e2 Support custom countSpec in SimpleJpaRepository.findAll(…).
Closes #3727
2025-05-16 12:25:50 +02:00
Mark Paluch
f670b10a0b Remove deprecated QuerydslJpaRepository.
Closes #3683
2025-05-16 12:25:50 +02:00
Mark Paluch
e6c2008e8e Document that fluent findBy(…) queries must return a result.
Closes #3294
2025-05-16 12:25:49 +02:00
Mark Paluch
65d0c51d4d Polishing.
Fix since versions.

See: #3521
Original Pull Request: #3578
2025-05-16 12:25:49 +02:00
Mark Paluch
63e09c926b Upgrade to Hibernate 7.0 Beta3.
Also, upgrade to Antlr 4.13.2 and extend XML metadata due to changes in how Hibernate now handles model metadata.

Closes #3723
2025-05-16 12:25:49 +02:00
Mark Paluch
0d46e05362 Remove OpenJPA leftovers.
Remove unused tests, simplify findAllById(Iterable) implementation.

Closes #3741
2025-05-16 12:25:49 +02:00
Mark Paluch
d2abc6176f Merge (Hql|Jpql|Eql)SpecificationTests with their corresponding QueryRendererTests.
Closes #3692
2025-05-16 12:25:49 +02:00
Mark Paluch
19571e4386 Polishing.
Refine JOIN and function keyword rendering.

See #3692
2025-05-16 12:25:49 +02:00