Add assertions and missing Override annotations. Avoid recursive self-call on getClassLoader. Extend documentation.
See #1627
Original pull request: #4389
We now set the skipOutput flag if an annotated Aggregation defines an $out stage and when the method is declared to return no result (void / Mono<Void>, kotlin.Unit)
Closes: #4088
Original pull request: #4341
This commit introduces the new `@Hint` annotation that allows to override MongoDB's default index selection for repository query, update and aggregate operations.
```
@Hint("lastname-idx")
List<Person> findByLastname(String lastname);
@Query(value = "{ 'firstname' : ?0 }", hint="firstname-idx")
List<Person> findByFirstname(String firstname);
```
Closes: #3230
Original pull request: #4339
Remove caching variant of MongoClientEncryption. Rename types for consistent key alt name scheme. Rename annotation to ExplicitEncrypted.
Add package-info. Improve documentation wording. Reduce visibility of KeyId and KeyAltName to package-private.
Original pull request: #4302
See: #4284
We now support explicit field encryption using mapped entities through the `@ExplicitEncrypted` annotation.
class Person {
ObjectId id;
@ExplicitEncrypted(algorithm = AEAD_AES_256_CBC_HMAC_SHA_512-Deterministic, altKeyName = "my-secret-key")
String socialSecurityNumber;
}
Encryption is applied transparently to all mapped entities leveraging the existing converter infrastructure.
Original pull request: #4302Closes: #4284
This commit makes sure to read query hints and apply them to the MongoDB UpdateOptions when running an update via Reactive-/MongoTemplate.
Original pull request: #4311Closes: #3218
We now use the springDocsUrl attribute provided via spring-projects/spring-data-build#1895 to resolve links to framework documentation.
Original Pull Request: #4267
We now make sure to provide an id value that matches the desired target type when no id is set, and the property defines an explicit conversion target.
Previously a new ObjectId would have been generated which leads to type inconsistencies when querying for _id.
Closes#4026
Original pull request: #4057.
The Collation annotation mainly serves as a meta annotation that allows common access to retrieving collation values for annotated queries, aggregations, etc.
Original Pull Request: #4131
Introduce Aggregation.stage which allows to use a plain JSON String or any valid Bson representation to be used within an aggregation pipeline stage, without having to implement AggregationOperation directly.
The change allows to make use of driver native builder API for aggregates.
Original pull request: #4059.
Closes#4038