-
Notifications
You must be signed in to change notification settings - Fork 38.5k
Data binding with immutable objects (Kotlin / Lombok / @ConstructorProperties) [SPR-15199] #19763
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Juergen Hoeller commented This connects nicely to an ongoing theme of ours: allowing for a more functional style. Based on the JavaBeans On a related note, Jackson supports |
Benjamin M commented Yeah, I know that Jackson supports this. I already can use Lombok with |
Aliaksei Zhynhiarouski commented So, implementing this feature, it will also will add support of Kotlin data classes? |
Juergen Hoeller commented Good point, this should easily work with Kotlin data classes as well... |
Juergen Hoeller commented We're now automatically detecting data classes with a single public constructor, resolving the constructor arguments against the request parameters, as long as the parameter names are retained or an |
Benjamin M opened SPR-15199 and commented
I'm trying to integrate Lombok with my Spring Project. Now I came across the first issue:
This will result in an Exception:
This happens because it's an immutable object, which sets all its values though its constructor.
Though it would be really nice if Spring could take care of
@ConstructorProperties
if there's no default constructor.Affects: 4.3.6, 5.0 M4
Issue Links:
Referenced from: commits fa4d139, 65ba865
The text was updated successfully, but these errors were encountered: