Commit Graph

3004 Commits

Author SHA1 Message Date
Christoph Strobl
647d9fd949 Provide RepositoryMethodMetadata during method invocation.
Provide context during repository method invocation to potential consumers.

See: #3090
Original Pull Request: #3093
2024-08-08 13:46:55 +02:00
Mark Paluch
4df7a164e9 Consider fragments and repository contributions via spring.factories.
Closes: #3090
Original Pull Request: #3093
2024-08-08 13:45:01 +02:00
Mark Paluch
201657e78a Polishing.
Update javadoc and fix formatting.

Original Pull Request: #3093
2024-08-08 13:44:05 +02:00
Mark Paluch
b6262b212e Upgrade to Maven Wrapper 3.9.8.
See #3134
2024-08-08 10:22:00 +02:00
Mark Paluch
43e0dc1da1 Update CI properties.
See #3098
2024-08-08 10:20:10 +02:00
Mark Paluch
1cdfb2e533 Fix KotlinCopyMethod detection for single-association property classes.
KotlinCopyMethod.shouldUsePublicCopyMethod(…) now considers single-association arrangements. Also, the method now early exists if pre-conditions aren't met.

Closes #3131
2024-08-06 15:14:35 +02:00
Oliver Drotbohm
0ba3937617 Explicitly reject invalid aggregate event registrations during publishing.
We now detect that the consumption of the events published during a persistence operation has produced new event instances that would go unpublished and raise an explaining exception. Previously such a scenario would've resulted in a ConcurrentModificationException.

We primarily reject such a scenario as handling the additional event would extend our convenience mechanism over the publishing scope a direct 1:1 replacement with ApplicationEventPublisher would've achieved.

Fixes GH-3116.
2024-08-06 09:02:18 +02:00
Christoph Strobl
1f347dce69 Add missing native image runtime hints for Jackson Page serialization.
Closes #3117
Original pull request: #3119
2024-08-05 14:53:03 +02:00
Eric Haag
d5608934b7 Migrate build to Spring Develocity Conventions extension.
* Migrate build to Spring Develocity Conventions extension.

* Adopt Develocity environment variables.

Closes #3130
2024-08-01 11:45:49 +02:00
Christoph Strobl
431a1f5179 Fix property lookup for projections on Kotlin types.
This commit makes sure to use the target objects method to determine the property used for the projection.

Closes: #3127
Original pull request: #3129
2024-08-01 11:43:02 +02:00
Mark Paluch
2ee3a866a6 Bundle Javadoc with Antora documentation site.
Closes #3128
2024-07-31 09:27:07 +02:00
Mark Paluch
bb833a145c Revise Repositories initialization.
We now no longer declare cacheRepositoryFactory as synchronized to avoid locking. Additionally, simplify the flow and reuse computed values as much as possible.

Closes #3126
2024-07-26 10:34:13 +02:00
Mark Paluch
3dd3932d49 Polishing.
Simplify assertions.

See #3125
2024-07-23 11:35:48 +02:00
Mark Paluch
8a8c92e503 Consider declaring class when evaluating method return type for query method post-processing.
We now consider the declaring class to properly resolve type variable references for the result post-processing of a query method result.

Previously, we attempted to resolve the return type without considering the actual repository class resolving always Object instead of the type parameter.

Closes #3125
2024-07-23 11:35:47 +02:00
Mark Paluch
71484159cf Introduce Parameter.getRequiredName() method.
Add getRequiredName to shortcut parameter name discovery and fast-fail in cases where the parameter name is required.

Closes #3124
2024-07-23 09:18:02 +02:00
Jens Schauder
9ab34d8672 Further refactoring of PageableExecutionUtils.
Removing `isSubsequentPage`. It is another name for !isFirstPage suggesting a different meaning which isn't there.

Extracting `if (isFirstPage(pageable)) {`, further structuring the decision tree.

See #3103
Original pull request #3113
2024-07-01 12:57:57 +02:00
erie0210
47109d4bb1 Refactor PageableExecutionUtils.
Closes #3103
Original pull request #3113
2024-07-01 12:51:17 +02:00
Christoph Strobl
ec3ba10954 Polishing.
Delegate annotation attribute resolution to configured BeanNameGenerator resolving method and test for enabling reactive repositories.

Original Pull Request: #3083
2024-06-26 11:07:15 +02:00
Mark Paluch
2a8402c0c3 Polishing.
Use constants where possible.

Original Pull Request: #3083
2024-06-26 11:06:24 +02:00
Mark Paluch
a37a700b59 Add support for BeanNameGenerator configuration in Enable…Repositories.
We now accept a dedicated BeanNameGenerator in our Enable…Repositories annotations to override the importBeanNameGenerator.

Closes: #3082
Original Pull Request: #3083
2024-06-26 11:05:55 +02:00
Mark Paluch
a115ee6a44 Filter delegated properties for Kotlin data classes.
We now filter delegated properties (such as lazy) from being managed as persistent properties.

Closes #3112
2024-06-24 11:51:49 +02:00
Mark Paluch
df2276a19d Remove Slack notification.
See #3110
2024-06-20 13:52:45 +02:00
Mark Paluch
a905bb2120 Switch to Broadcom docker proxy.
Closes #3110
2024-06-20 13:52:33 +02:00
Mark Paluch
5c120dde29 Polishing.
Fix snapshot repository URL.

See #3097
2024-06-18 11:38:27 +02:00
Mark Paluch
2bed1f2ee5 Ignore getters for Kotlin types deviating from Java Beans spec.
We now ignore Kotlin getters that are either static methods or would require additional arguments.

Closes #3109
2024-06-18 11:33:03 +02:00
Mark Paluch
0e9dc7aec4 Polishing.
Provide load-factor to sets with well-known sizing, move annotation auditing metadata cache to DefaultAuditableBeanWrapperFactory to avoid strong static references.

See #3067
Original pull request: #3073
2024-06-13 13:56:38 +02:00
Christoph Strobl
b21b2e8934 Align internal caches with core framework patterns.
Initialize maps and sets with size where possible.

Closes #3067
Original pull request: #3073
2024-06-13 13:56:38 +02:00
Mark Paluch
d4301eea78 Populate DTO projection properties that are considered associations.
We now populate DTO properties whose are identified as associations. While uncommon, as typically entities declare assocations using entities, associations can be identified as types and so these are now considered when populating properties.

Closes #3104
2024-06-10 14:58:07 +02:00
Mark Paluch
857a239ec8 Polishing.
Defer message creation. Add test.

See #3091
2024-06-10 11:27:56 +02:00
kgignatyev
b822c5f9f4 Add offending type name to AbstractRepositoryMetadata verification exception message.
Closes #3091
2024-06-10 11:27:55 +02:00
Oliver Drotbohm
0a603f2e57 Use legacy page serialization mode if no SpringDataWebSettings are present.
Fixes GH-3101.
2024-05-30 23:34:48 +02:00
Mark Paluch
19e2a1c925 After release cleanups.
See #3079
2024-05-17 11:51:34 +02:00
Mark Paluch
9f8d37dfb1 Prepare next development iteration.
See #3079
2024-05-17 11:51:32 +02:00
Mark Paluch
119e12af20 Release version 3.3 GA (2024.0.0).
See #3079
2024-05-17 11:49:25 +02:00
Mark Paluch
147f46d940 Prepare 3.3 GA (2024.0.0).
See #3079
2024-05-17 11:49:10 +02:00
Oliver Drotbohm
b09c503480 Polishing.
Ternary ifs and less nesting.

Related: GH-3094
Original pull request: GH-2865
2024-05-14 11:38:36 +02:00
Yanming Zhou
ae76d08403 Use Pageable.unpaged(sort) for sorted unpaged pageable.
The (Reactive)PageableHandlerMethodArgumentResolver now falls back to a unpaged Pageable instance with a resolved sort if the the resolved Pageable is unpaged.

Fixes: GH-3094
Original pull request: GH-2865
2024-05-14 11:38:04 +02:00
Alessandro Rubino
c2a475b42c Update links to direct section links.
Closes #3095
2024-05-14 09:54:43 +02:00
Mark Paluch
2f43bd593e Limit generics length to declared length.
Also, rename method to reflect what it actually returns.
Document generic usage constraints in RepositoryFactoryBeanSupport subclasses.

Closes #3089
2024-05-08 09:54:09 +02:00
Mark Paluch
18d31ec61d Document how projection types relate to the entity type hierarchy.
Closes #3092
2024-05-07 15:17:43 +02:00
Mark Paluch
b1a5fc460b Apply Kotlin Value Class unboxing to generated Property Accessors.
Unwrap wrapped value types if necessary when using generated property accessors.

Closes #3087
2024-04-29 09:12:57 +02:00
Mark Paluch
00d03c595b Polishing.
Add missing Javadoc and Serial annotations. Simplify code.

See #3081
2024-04-24 09:38:51 +02:00
Jan Kurella
7bac883930 Avoid NullPointerException´ and IllegalArgumentException for control flow in Sort`.
Checking for null explicitly is cheap and prevents two unnecessary Exception
objects creations.

Closes #3081
2024-04-24 09:38:15 +02:00
Mark Paluch
027b8c2ad2 Fix StackOverflowError in TypeDiscoverer comparison.
We now resort to String-based comparison if a generic cannot be resolved. Previously, unresolved generics caused an infinite recursion.

Closes #3084
2024-04-23 10:17:53 +02:00
Alexander Münch
2f9427a94b Fix typo in object-mapping.adoc.
Closes #3076
2024-04-15 15:15:16 +02:00
Mark Paluch
5d067c56cd Polishing.
Reformat code. Use explicit local variable types instead of var.

See #3075
2024-04-15 15:11:42 +02:00
Yanming Zhou
797066dcc0 Use -1 instead of null as initial OffsetScrollPosition.
1. Use type `long` instead of `Long` to keep it consistent with previous version.
2. Position function is simplified to `offset+1`.

Closes #3075
2024-04-15 15:07:46 +02:00
Mark Paluch
1771647cb2 After release cleanups.
See #3065
2024-04-12 10:52:59 +02:00
Mark Paluch
04c5135b98 Prepare next development iteration.
See #3065
2024-04-12 10:52:58 +02:00
Mark Paluch
dd42cb2a51 Release version 3.3 RC1 (2024.0.0).
See #3065
2024-04-12 10:50:41 +02:00