-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Null coercion with @JsonSetter
does not work with java.lang.Record
#2974
Comments
Oh boy. This gets deeper and deeper. But long and short of this is that there IS one specific work-around: name your constructor parameters and linkage works. For example:
Not pretty but works. I'll see if this can be fixed more generally but this is the workaround for now. |
Ok so the problem is as follows:
Now: there are couple of ways things could be improved. For example, either
of these, first option seems more likely for 2.x; second better overall (and hence for 3.x). So marking this as 2.13, unlikely to be attempted for 2.12.x. |
Looks like use of
@JsonSetter(nulls=...)
does not work with Records in 2.12.0.Note that earlier report (#2970) turned out to be valid, but since I closed it earlier decided to file a separate one.
The text was updated successfully, but these errors were encountered: