Jackson Error "no delegate- or property-based Creator" on trying to use record after upgrading to 2.15.3 #202
Replies: 5 comments 2 replies
-
The release notes are here - https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.15 There were many changes in Jackson 2.15 to fix issues in Record support. I would suggest that you should experiment with changing the visibility settings. This is a volunteer project and it helps the volunteers if the reporters do some of the investigation. |
Beta Was this translation helpful? Give feedback.
-
FasterXML/jackson-databind#4105 It looks like the above issue |
Beta Was this translation helpful? Give feedback.
-
I would recommend trying this with just released 2.16.1. As @pjfanning mentioned there has been a lot of recent work to try to make record types work better, esp. with default settings. Conversely less common use cases -- like tweaking visibility settings -- are not as well covered. But regardless of issue it is often best to try out later versions and see if the issue might already be fixed; this is often the case. |
Beta Was this translation helpful? Give feedback.
-
But specifically on this example: you have:
which essentially says: "Do NOT try to find constructor for me, I will annotate one to use". It may well be the case that 2.14 was incorrectly ignoring this visibility setting and 2.15 behavior is correct one. So unless you really have a good reason to use that setting, I would remove it, or changed to at least find EDIT: above is incorrect, see my later comment. |
Beta Was this translation helpful? Give feedback.
-
@cowtowncoder The behaviour of the 2.16.1 is the same as in 2.14.3. The above code is working fine with 2.16.1 also. I have placed the sample code in https://github.com/debraj-spotnana/jackson-issue/tree/main. In 2.15.3 if I change the I am a bit confused now, what is the correct behaviour? The explanation that you gave about |
Beta Was this translation helpful? Give feedback.
-
The below code is throwing the error with Jackson 2.15.3 but the same has been working fine with 2.14.3.
The exception I am getting with Jackson 2.15.3 is like below
Is this expected with Jackson 2.15.3? Can someone let me know what change in jackson 2.15.3 lead to this?
Beta Was this translation helpful? Give feedback.
All reactions