Avoid nullability in RepositoryMethodContextHolder.getContext(). Introduce shortcut in RepositoryMethodContext to obtain the current thread-local context. Update documentation.
See #3175.
Original pull request: #3176
RepositoryMethodContext are now made available for dependency injection via RepositoryConfigurationExtensionSupport.registerBeansForRoot(…). Moved RMC into repository.core package (previously repository.core.support) and only expose factory methods on DefaultRepositoryMethodContext. DRMC also exposes a injection proxy lookup method that creates a proxy equipped with a TargetSource delegating to DRMC.getInstance() (previously ….getContext()). An additional, static DRMC.forMethod(…) allows the creation of a default instance for testing purposes.
Rename getRepository() to getMetadata() on RMC.
Fixes#3175.
Original pull request: #3176
Introduce ValueExpressionQueryRewriter as replacement for SpelQueryContext and QueryMethodValueEvaluationContextAccessor to encapsulate common ValueExpression functionality for Spring Data modules wanting to resolve Value Expressions in query methods.
Reduce dependencies in RepositoryFactoryBeanSupport and RepositoryFactorySupport to EvaluationContextProvider instead of QueryMethodEvaluationContextProvider to simplify dependencies.
Deprecate QueryMethodEvaluationContextProvider and its reactive variant for future removal.
Closes#3049
Original pull request: #3050
This commit adds a required native image reflection hint to allow Jackson object mapping to resolve and invoke the constructor of PageMetadata.
It also fixes an issue that surfaced after changing the bean constructor argument for SpringDataWebSettings leading to failures during the native compilation.
Closes: #3171
Update documentation.
Additional logging for repository bootstrap procedure.
Limit usage of Optional in RepositoryFragment.
Original Pull Request: #3145
Repositories that detect fragment implementations implementing RepositoryMetadataAccess enable metadata exposure regardless of the exposeMetadata flag.
See: #3090
Original Pull Request: #3145
We now attempt to detect property accessors for properties declared in Kotlin that do not have a Kotlin-style accessor but one that instead comes from an interface.
Also, we specialize accessor methods that are inherited from a Java superclass but override accessors in the Kotlin realm.
Closes#3140Closes#3146
We now explicitly do not match handler method parameters that are annotated with anything but @ModelAttribute or @ProjectedPayload. This prevents us accidentally opting into parameter handling for annotated parameters that use interfaces for their declaration and are supposed to be handled by some other infrastructure.
Fixes GH-2937.
We now refrain from registering a SpringDataWebSettings instance as bean in the ApplicationContext if @EnableSpringDataWebSupport is used without an explicit declaration of pageSerializationMode. This allows Spring Boot to use the annotation, but allow the attribute value to be configured via a property at the same time.
See https://github.com/spring-projects/spring-boot/pull/39797#discussion_r1508396169 for details.
Fixes GH-3054.
Registering a StdConverter with Jackson to log a warning about the Page serialization mode causes the target serializer to be only built for Page losing additional properties defined on extensions. We now instead register a no-op BeanSerializerModifier that issues the warning and doesn't affect the serializer selection.
Fixes GH-3137.
KotlinCopyMethod.shouldUsePublicCopyMethod(…) now considers single-association arrangements. Also, the method now early exists if pre-conditions aren't met.
Closes#3131
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.