-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
@JsonProperty(access = Access.READ_ONLY) does not work #2779
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
To be precise, you would like field to be quietly ignored, and not trigger exception. That makes sense. |
My workaround right now is Yes, the field should be ignored when deserializing. |
I can reproduce the issue with 2.11.1, but it is actually fixed for 2.12, most likely wrt #2719. Due to non-trivial changes needed by fix I will not try to backport this to earlier versions; fix will be in 2.12.0. I will add a test to guard against regression however. |
I have a similar bean and in response I get output as expected that works is serialized properly.
In postman it works fine. |
@RakshithVP please note that this is fixed for 2.12 but there is no 2.12.0 release yet -- 2.11.2 does not have the fix. If you can use 2.12.0-SNAPSHOT version (either via sonatype OSS repo or using local build) you may want to see if that is fixed. |
May I know when is the release of 2.12.0 planned? |
@RakshithVP earlier I was hoping to get release out by September 2020, but that may slip -- I still hope the first release candidate would be out in september. |
Fails to work with 2.11.1
Test to reproduce the issue:
Bug.java
Bean.java
Exception:
Expected behaviour:
The property should only be serialized. However, it is being tried to deserialized.
This bug was supposed to be fixed with #935
The text was updated successfully, but these errors were encountered: