Closed w3-3w closed 9 months ago
These are actually two issues, I created #1688 to track the problem with properties not existent in the projection type which is an actual bug.
Up to now, we instantiate the underlying entity type with a smaller set of properties to then apply a projection on top. Due to class design restrictions, especially Kotlin's non-null by default, we should use a different mechanism that doesn't require entity instantiation.
TL;DR: When using combination of Kotlin and R2dbc, interface-based and class-based projection does not work as described in documentation.
Spring Data Version: 3.2.0
Example:
For (1), the whole application fails to start with exception:
For (2), exception is like: