Introduce EmptyDocument and utility methods in BsonUtils. Avoid entrySet and iterator creation for document iterations/inspections.
Relates to: #3760
Original Pull Request: #3809
SessionSynchronization.NEVER bypasses all transactional integration in cases where applications do not want to make use of transactions so that transaction inspection overhead is avoided.
Closes: #3760
Original Pull Request: #3809
We now simply delegate to AnnotationBasedPersistentProperty.isIdProperty() for the detection of annotated identifiers. The previous, manual identifier check was preventing additional identifier annotations, supported by ABP, to be considered, too.
Fixes#3803.
This commit adds support for relational style One-To-Many references using a combination of ReadonlyProperty and @DocumentReference.
It allows to link types without explicitly storing the linking values within the document itself.
@Document
class Publisher {
@Id
ObjectId id;
// ...
@ReadOnlyProperty
@DocumentReference(lookup="{'publisherId':?#{#self._id} }")
List<Book> books;
}
Closes: #3798
Original pull request: #3802.
We now no longer attempt to convert query Documents into primitive types to avoid e.g. Document to String conversion.
Closes: #3783
Original Pull Request: #3797
This commit fixes an issue where a defined custom target type conversion for the id field was not properly considered when writing a document reference. Previously an eg. String was not being converted into an ObjectId correctly causing lookup queries to return empty results.
Converting the id property value on write solves the issue.
Includes a minor polish in the mapping centralizing pointer creation within the DocumentPointerFactory.
Closes: #3782
Original pull request: #3785.
Add support for Pattern. Extract Regex flags translation from Criteria into RegexFlags utility class. Add since and author tags. Simplify tests. Update reference documentation.
See #3725.
Original pull request: #3781.
Introduce factory methods to convert TimeZone/ZoneId/ZoneOffset into Mongo Timezone. Introduce TemporalUnit abstraction and converters to convert ChronoUnit and TimeUnit into TemporalUnit for date operators accepting a unit parameter.
See #3713
Original pull request: #3748.
Make fields final where possible. Update javadoc. Simplify assertions. Update reference docs.
See: #3715, See #3717, See #3727
Original pull request: #3741.