Skip to content

Conversation

@mp911de
Copy link
Member

@mp911de mp911de commented Dec 1, 2021

MappingMongoConverter now is able to materialize projections without creating intermediate entities. That allows bypassing nullability restrictions of entities when e.g. using Kotlin. Interface projections are always backed by a Map, DTO projections use the target class to merge its metadata with the domain type metadata to e.g. allow overrides of field names.

Depends on spring-projects/spring-data-commons#2420

TODO: Field annotations on projection types no longer considered, simple DTO's without accessors not considered DTO projections, causes conversion issues.
Consider merged mapping metadata for DTO projections that may shadow entity properties or may contain additional Field annotations.
christophstrobl added a commit that referenced this pull request Dec 14, 2021
Add tests for projections on dbref properties update java- and reference documentation.

Original Pull Request: #3894
@christophstrobl christophstrobl deleted the issue/2860 branch December 14, 2021 11:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

status: waiting-for-triage An issue we've not yet triaged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support nested level projections through interface-based projection [DATAMONGO-1989]

4 participants