-
-
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
2.15.0 breaking behaviour change for records and Getter Visibility #3895
Comments
Wrong repo, moving. |
@matteobertozzi We publish RC versions -- 2.15.0-rc1, rc2, rc3 -- to find these kinds of concerns; cases that are not supported explicitly (there not being unit tests to cover). So one way to think of it is that unless we test something, and no one contributes tests, feature is not formally supported. This does not mean that usage might not be intended to work: there are gaps. Having said that, I think I agree that if Field visibility is set to I am guessing #3894 would solve this issue? |
i'm really sorry to have not tested the RCs. #3894 should solve this one Thank you! |
@matteobertozzi can you share the reason for that config? Is the reason the same as #3628? |
@yihtserns the main reason is because we have "bad code". with classes that contains methods called "getXyz()" but they are not getters and they are doing computations and maybe some business logic. so if we use something different from .GETTERS = Visbility.NONE, we end up with a value that is not supposed to be serialized and maybe some business logic triggered. public class Foo {
private final int x = 2;
public int getComputedValue() { return 11; }
}
jsonMapper.writeValueAsString(new Foo()) // { x: 2, computedValue: 11 } going around all the methods in the codebase to add annotations may be fine for a major (e.g. the 3.x) but we didn't expect that for a minor. |
@matteobertozzi Sorry did not mean that you specifically should have tested, just that it is too bad no one with this use case had tried it and reported. There are gaps, hopefully over time fewer and fewer. So this is a surprise to us and not a planned behavioral change. |
It is probably related that since version 2.15 The property 'a' in the example below comes at the last place: final var mapper =
Jackson.mapperBuilder()
.enable(SerializationFeature.INDENT_OUTPUT)
.enable(MapperFeature.SORT_PROPERTIES_ALPHABETICALLY)
.build();
record R(String c, String b, String e) {
@JsonProperty
String a() {
return "4";
}
}
System.out.println(mapper.writeValueAsString(new R("1", "2", "3"))); Output: { |
@agavrilov76 can you create another issue for that? It's not related to this, but rather is caused by #3724. |
Would #3894 fix solve this as well? I just merged the fix. |
Hi, I did run my tests with the 2.15.1-20230504.033533-11 SNAPSHOT Thanks! <repositories>
<repository>
<id>oss.sonatype.snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<properties>
<jackson.version>2.15.1-SNAPSHOT</jackson.version>
... |
Thank you @matteobertozzi ! |
I just discovered that the default mapper configuration for the Azure SDK for Java is: .visibility(PropertyAccessor.FIELD, Visibility.ANY)
.visibility(PropertyAccessor.GETTER, Visibility.NONE) Upgrading |
commit f083348 Merge: 6091c4b 3291911 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:53:20 2023 -0700 Merge branch '2.15' into 2.16 commit 3291911 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:49:51 2023 -0700 Back to snapshot dep commit 05472ae Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:47:37 2023 -0700 [maven-release-plugin] prepare for next development iteration commit 6e37325 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:47:34 2023 -0700 [maven-release-plugin] prepare release jackson-databind-2.15.1 commit 3d9dd34 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:34:13 2023 -0700 2.15.1 release commit 6091c4b Merge: d2ae3a2 55d87cf Author: Tatu Saloranta <[email protected]> Date: Tue May 16 12:38:57 2023 -0700 Merge branch '2.15' into 2.16 commit 55d87cf Merge: a7e17ad c7b6c64 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 12:38:24 2023 -0700 Merge branch '2.14' into 2.15 commit c7b6c64 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 12:35:44 2023 -0700 Fix FasterXML#3882 (JsonNode.withArray() fail) commit d2ae3a2 Author: Tatu Saloranta <[email protected]> Date: Mon May 15 21:06:11 2023 -0700 manual merge of pom.xml (test) change commit 7ddce07 Merge: a3bb1b9 a7e17ad Author: Tatu Saloranta <[email protected]> Date: Mon May 15 21:02:46 2023 -0700 Merge branch '2.15' into 2.16 commit a7e17ad Author: Tatu Saloranta <[email protected]> Date: Mon May 15 21:01:49 2023 -0700 Add Junit 5 test dependency commit a3bb1b9 Merge: a3b231c 8a8ba5a Author: Tatu Saloranta <[email protected]> Date: Mon May 15 18:13:22 2023 -0700 Merge branch '2.15' into 2.16 commit 8a8ba5a Author: Kim, Joo Hyuk <[email protected]> Date: Tue May 16 10:13:07 2023 +0900 Update JavaDoc of JsonAppend. (FasterXML#3933) commit a3b231c Author: Tatu Saloranta <[email protected]> Date: Mon May 15 15:38:40 2023 -0700 Update release notes wrt FasterXML#3928 commit 40c9739 Author: PJ Fanning <[email protected]> Date: Mon May 15 23:32:27 2023 +0100 Json property affects Record field serialization order (FasterXML#3929) commit 8fcf9ef Merge: e9db4b3 e5bdcfb Author: Tatu Saloranta <[email protected]> Date: Sun May 14 17:08:35 2023 -0700 Merge branch '2.15' into 2.16 commit e5bdcfb Author: Kim, Joo Hyuk <[email protected]> Date: Mon May 15 09:06:35 2023 +0900 Remove hard-coded `StreamReadConstraints` test variables to isolate change in `jackson-core` itself (FasterXML#3930) commit e9db4b3 Author: Piotr Findeisen <[email protected]> Date: Mon May 15 02:04:42 2023 +0200 Fix typo in USE_GETTERS_AS_SETTERS description (FasterXML#3931) commit d8d4cb6 Author: Tatu Saloranta <[email protected]> Date: Sat May 13 20:15:45 2023 -0700 Sync tests wrt error messages commit c1b4aad Merge: 67103c2 6f81a4e Author: Tatu Saloranta <[email protected]> Date: Sat May 13 20:04:42 2023 -0700 Merge branch '2.15' into 2.16 commit 6f81a4e Author: Tatu Saloranta <[email protected]> Date: Sat May 13 20:02:20 2023 -0700 Minor change to align with higher max string value length limit commit 67103c2 Author: Tatu Saloranta <[email protected]> Date: Sat May 6 09:44:18 2023 -0700 Clean up attic... commit cfe8e97 Author: Muhammad Khalikov <[email protected]> Date: Sat May 6 12:43:35 2023 -0400 Fix a few typos in documentation (FasterXML#3919) commit df541d3 Author: Kim, Joo Hyuk <[email protected]> Date: Sat May 6 12:32:13 2023 +0900 Improve and fix JavaDocs for Jackson 2.15 (FasterXML#3917) commit d44e014 Merge: 924152d c8c7d39 Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:36:27 2023 -0700 Merge branch '2.15' into 2.16 commit c8c7d39 Merge: a7a8a80 d47d1b6 Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:36:21 2023 -0700 Merge branch '2.14' into 2.15 commit d47d1b6 Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:34:29 2023 -0700 Back to snapshot dep commit 6f3d20f Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:31:43 2023 -0700 [maven-release-plugin] prepare for next development iteration commit 8cdba21 Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:31:40 2023 -0700 [maven-release-plugin] prepare release jackson-databind-2.14.3 commit 2bd50de Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:09:17 2023 -0700 Prepare for 2.14.3 release commit 924152d Merge: 774ddb8 a7a8a80 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 14:00:26 2023 -0700 Merge branch '2.15' into 2.16 commit a7a8a80 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 14:00:13 2023 -0700 ... commit 774ddb8 Merge: f847745 ad308b4 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 13:57:18 2023 -0700 Merge branch '2.15' into 2.16 commit ad308b4 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 13:55:48 2023 -0700 Update release notes wrt FasterXML#3897 commit 1fa2d86 Author: Sim Yih Tsern <[email protected]> Date: Fri May 5 04:52:30 2023 +0800 Record constructor with single write-only parameter should result in properties-based creator, to fix FasterXML#3897. (FasterXML#3910) commit f847745 Merge: f3c60ed ee3b89a Author: Tatu Saloranta <[email protected]> Date: Thu May 4 11:13:22 2023 -0700 Merge branch '2.16' of github.com:FasterXML/jackson-databind into 2.16 commit f3c60ed Merge: 23603ea 7547591 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 11:13:15 2023 -0700 Merge branch '2.15' into 2.16 commit 7547591 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 11:12:53 2023 -0700 Mark FasterXML#3895 as fixed (due to another PR/issue) commit ee3b89a Author: ChangYong <[email protected]> Date: Fri May 5 02:09:33 2023 +0900 Fix incorrect comment (FasterXML#3916)
commit f083348 Merge: 6091c4b 3291911 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:53:20 2023 -0700 Merge branch '2.15' into 2.16 commit 3291911 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:49:51 2023 -0700 Back to snapshot dep commit 05472ae Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:47:37 2023 -0700 [maven-release-plugin] prepare for next development iteration commit 6e37325 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:47:34 2023 -0700 [maven-release-plugin] prepare release jackson-databind-2.15.1 commit 3d9dd34 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:34:13 2023 -0700 2.15.1 release commit 6091c4b Merge: d2ae3a2 55d87cf Author: Tatu Saloranta <[email protected]> Date: Tue May 16 12:38:57 2023 -0700 Merge branch '2.15' into 2.16 commit 55d87cf Merge: a7e17ad c7b6c64 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 12:38:24 2023 -0700 Merge branch '2.14' into 2.15 commit c7b6c64 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 12:35:44 2023 -0700 Fix FasterXML#3882 (JsonNode.withArray() fail) commit d2ae3a2 Author: Tatu Saloranta <[email protected]> Date: Mon May 15 21:06:11 2023 -0700 manual merge of pom.xml (test) change commit 7ddce07 Merge: a3bb1b9 a7e17ad Author: Tatu Saloranta <[email protected]> Date: Mon May 15 21:02:46 2023 -0700 Merge branch '2.15' into 2.16 commit a7e17ad Author: Tatu Saloranta <[email protected]> Date: Mon May 15 21:01:49 2023 -0700 Add Junit 5 test dependency commit a3bb1b9 Merge: a3b231c 8a8ba5a Author: Tatu Saloranta <[email protected]> Date: Mon May 15 18:13:22 2023 -0700 Merge branch '2.15' into 2.16 commit 8a8ba5a Author: Kim, Joo Hyuk <[email protected]> Date: Tue May 16 10:13:07 2023 +0900 Update JavaDoc of JsonAppend. (FasterXML#3933) commit a3b231c Author: Tatu Saloranta <[email protected]> Date: Mon May 15 15:38:40 2023 -0700 Update release notes wrt FasterXML#3928 commit 40c9739 Author: PJ Fanning <[email protected]> Date: Mon May 15 23:32:27 2023 +0100 Json property affects Record field serialization order (FasterXML#3929) commit 8fcf9ef Merge: e9db4b3 e5bdcfb Author: Tatu Saloranta <[email protected]> Date: Sun May 14 17:08:35 2023 -0700 Merge branch '2.15' into 2.16 commit e5bdcfb Author: Kim, Joo Hyuk <[email protected]> Date: Mon May 15 09:06:35 2023 +0900 Remove hard-coded `StreamReadConstraints` test variables to isolate change in `jackson-core` itself (FasterXML#3930) commit e9db4b3 Author: Piotr Findeisen <[email protected]> Date: Mon May 15 02:04:42 2023 +0200 Fix typo in USE_GETTERS_AS_SETTERS description (FasterXML#3931) commit d8d4cb6 Author: Tatu Saloranta <[email protected]> Date: Sat May 13 20:15:45 2023 -0700 Sync tests wrt error messages commit c1b4aad Merge: 67103c2 6f81a4e Author: Tatu Saloranta <[email protected]> Date: Sat May 13 20:04:42 2023 -0700 Merge branch '2.15' into 2.16 commit 6f81a4e Author: Tatu Saloranta <[email protected]> Date: Sat May 13 20:02:20 2023 -0700 Minor change to align with higher max string value length limit commit 67103c2 Author: Tatu Saloranta <[email protected]> Date: Sat May 6 09:44:18 2023 -0700 Clean up attic... commit cfe8e97 Author: Muhammad Khalikov <[email protected]> Date: Sat May 6 12:43:35 2023 -0400 Fix a few typos in documentation (FasterXML#3919) commit df541d3 Author: Kim, Joo Hyuk <[email protected]> Date: Sat May 6 12:32:13 2023 +0900 Improve and fix JavaDocs for Jackson 2.15 (FasterXML#3917) commit d44e014 Merge: 924152d c8c7d39 Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:36:27 2023 -0700 Merge branch '2.15' into 2.16 commit c8c7d39 Merge: a7a8a80 d47d1b6 Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:36:21 2023 -0700 Merge branch '2.14' into 2.15 commit d47d1b6 Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:34:29 2023 -0700 Back to snapshot dep commit 6f3d20f Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:31:43 2023 -0700 [maven-release-plugin] prepare for next development iteration commit 8cdba21 Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:31:40 2023 -0700 [maven-release-plugin] prepare release jackson-databind-2.14.3 commit 2bd50de Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:09:17 2023 -0700 Prepare for 2.14.3 release commit 924152d Merge: 774ddb8 a7a8a80 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 14:00:26 2023 -0700 Merge branch '2.15' into 2.16 commit a7a8a80 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 14:00:13 2023 -0700 ... commit 774ddb8 Merge: f847745 ad308b4 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 13:57:18 2023 -0700 Merge branch '2.15' into 2.16 commit ad308b4 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 13:55:48 2023 -0700 Update release notes wrt FasterXML#3897 commit 1fa2d86 Author: Sim Yih Tsern <[email protected]> Date: Fri May 5 04:52:30 2023 +0800 Record constructor with single write-only parameter should result in properties-based creator, to fix FasterXML#3897. (FasterXML#3910) commit f847745 Merge: f3c60ed ee3b89a Author: Tatu Saloranta <[email protected]> Date: Thu May 4 11:13:22 2023 -0700 Merge branch '2.16' of github.com:FasterXML/jackson-databind into 2.16 commit f3c60ed Merge: 23603ea 7547591 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 11:13:15 2023 -0700 Merge branch '2.15' into 2.16 commit 7547591 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 11:12:53 2023 -0700 Mark FasterXML#3895 as fixed (due to another PR/issue) commit ee3b89a Author: ChangYong <[email protected]> Date: Fri May 5 02:09:33 2023 +0900 Fix incorrect comment (FasterXML#3916)
commit 63a7b1d Merge: 559cd04 3140bb7 Author: Tatu Saloranta <[email protected]> Date: Thu May 18 16:47:22 2023 -0700 Merge branch '2.15' into 2.16 commit 3140bb7 Merge: 4e1c9be 9f80462 Author: Tatu Saloranta <[email protected]> Date: Thu May 18 16:46:48 2023 -0700 Merge branch '2.15' of github.com:FasterXML/jackson-databind into 2.15 commit 559cd04 Merge: f083348 4e1c9be Author: Tatu Saloranta <[email protected]> Date: Thu May 18 16:45:27 2023 -0700 Merge branch '2.15' into 2.16 commit 9f80462 Author: Tatu Saloranta <[email protected]> Date: Thu May 18 16:44:56 2023 -0700 Fix FasterXML#3938: do not skip Method-based setters on Records (FasterXML#3939) commit 4e1c9be Merge: 3168975 c524e6b Author: Tatu Saloranta <[email protected]> Date: Thu May 18 15:54:01 2023 -0700 Merge branch '2.14' into 2.15 commit c524e6b Author: Tatu Saloranta <[email protected]> Date: Thu May 18 15:53:45 2023 -0700 Fix FasterXML#3938 to repro actual issue commit 3168975 Merge: 3291911 04d7ae4 Author: Tatu Saloranta <[email protected]> Date: Thu May 18 15:18:36 2023 -0700 Merge branch '2.14' into 2.15 commit 04d7ae4 Author: Tatu Saloranta <[email protected]> Date: Thu May 18 15:13:41 2023 -0700 Add passing test (in 2.14) for FasterXML#3938 commit f083348 Merge: 6091c4b 3291911 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:53:20 2023 -0700 Merge branch '2.15' into 2.16 commit 3291911 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:49:51 2023 -0700 Back to snapshot dep commit 05472ae Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:47:37 2023 -0700 [maven-release-plugin] prepare for next development iteration commit 6e37325 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:47:34 2023 -0700 [maven-release-plugin] prepare release jackson-databind-2.15.1 commit 3d9dd34 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 14:34:13 2023 -0700 2.15.1 release commit 6091c4b Merge: d2ae3a2 55d87cf Author: Tatu Saloranta <[email protected]> Date: Tue May 16 12:38:57 2023 -0700 Merge branch '2.15' into 2.16 commit 55d87cf Merge: a7e17ad c7b6c64 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 12:38:24 2023 -0700 Merge branch '2.14' into 2.15 commit c7b6c64 Author: Tatu Saloranta <[email protected]> Date: Tue May 16 12:35:44 2023 -0700 Fix FasterXML#3882 (JsonNode.withArray() fail) commit d2ae3a2 Author: Tatu Saloranta <[email protected]> Date: Mon May 15 21:06:11 2023 -0700 manual merge of pom.xml (test) change commit 7ddce07 Merge: a3bb1b9 a7e17ad Author: Tatu Saloranta <[email protected]> Date: Mon May 15 21:02:46 2023 -0700 Merge branch '2.15' into 2.16 commit a7e17ad Author: Tatu Saloranta <[email protected]> Date: Mon May 15 21:01:49 2023 -0700 Add Junit 5 test dependency commit a3bb1b9 Merge: a3b231c 8a8ba5a Author: Tatu Saloranta <[email protected]> Date: Mon May 15 18:13:22 2023 -0700 Merge branch '2.15' into 2.16 commit 8a8ba5a Author: Kim, Joo Hyuk <[email protected]> Date: Tue May 16 10:13:07 2023 +0900 Update JavaDoc of JsonAppend. (FasterXML#3933) commit a3b231c Author: Tatu Saloranta <[email protected]> Date: Mon May 15 15:38:40 2023 -0700 Update release notes wrt FasterXML#3928 commit 40c9739 Author: PJ Fanning <[email protected]> Date: Mon May 15 23:32:27 2023 +0100 Json property affects Record field serialization order (FasterXML#3929) commit 8fcf9ef Merge: e9db4b3 e5bdcfb Author: Tatu Saloranta <[email protected]> Date: Sun May 14 17:08:35 2023 -0700 Merge branch '2.15' into 2.16 commit e5bdcfb Author: Kim, Joo Hyuk <[email protected]> Date: Mon May 15 09:06:35 2023 +0900 Remove hard-coded `StreamReadConstraints` test variables to isolate change in `jackson-core` itself (FasterXML#3930) commit e9db4b3 Author: Piotr Findeisen <[email protected]> Date: Mon May 15 02:04:42 2023 +0200 Fix typo in USE_GETTERS_AS_SETTERS description (FasterXML#3931) commit d8d4cb6 Author: Tatu Saloranta <[email protected]> Date: Sat May 13 20:15:45 2023 -0700 Sync tests wrt error messages commit c1b4aad Merge: 67103c2 6f81a4e Author: Tatu Saloranta <[email protected]> Date: Sat May 13 20:04:42 2023 -0700 Merge branch '2.15' into 2.16 commit 6f81a4e Author: Tatu Saloranta <[email protected]> Date: Sat May 13 20:02:20 2023 -0700 Minor change to align with higher max string value length limit commit 67103c2 Author: Tatu Saloranta <[email protected]> Date: Sat May 6 09:44:18 2023 -0700 Clean up attic... commit cfe8e97 Author: Muhammad Khalikov <[email protected]> Date: Sat May 6 12:43:35 2023 -0400 Fix a few typos in documentation (FasterXML#3919) commit df541d3 Author: Kim, Joo Hyuk <[email protected]> Date: Sat May 6 12:32:13 2023 +0900 Improve and fix JavaDocs for Jackson 2.15 (FasterXML#3917) commit d44e014 Merge: 924152d c8c7d39 Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:36:27 2023 -0700 Merge branch '2.15' into 2.16 commit c8c7d39 Merge: a7a8a80 d47d1b6 Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:36:21 2023 -0700 Merge branch '2.14' into 2.15 commit d47d1b6 Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:34:29 2023 -0700 Back to snapshot dep commit 6f3d20f Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:31:43 2023 -0700 [maven-release-plugin] prepare for next development iteration commit 8cdba21 Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:31:40 2023 -0700 [maven-release-plugin] prepare release jackson-databind-2.14.3 commit 2bd50de Author: Tatu Saloranta <[email protected]> Date: Fri May 5 09:09:17 2023 -0700 Prepare for 2.14.3 release commit 924152d Merge: 774ddb8 a7a8a80 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 14:00:26 2023 -0700 Merge branch '2.15' into 2.16 commit a7a8a80 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 14:00:13 2023 -0700 ... commit 774ddb8 Merge: f847745 ad308b4 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 13:57:18 2023 -0700 Merge branch '2.15' into 2.16 commit ad308b4 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 13:55:48 2023 -0700 Update release notes wrt FasterXML#3897 commit 1fa2d86 Author: Sim Yih Tsern <[email protected]> Date: Fri May 5 04:52:30 2023 +0800 Record constructor with single write-only parameter should result in properties-based creator, to fix FasterXML#3897. (FasterXML#3910) commit f847745 Merge: f3c60ed ee3b89a Author: Tatu Saloranta <[email protected]> Date: Thu May 4 11:13:22 2023 -0700 Merge branch '2.16' of github.com:FasterXML/jackson-databind into 2.16 commit f3c60ed Merge: 23603ea 7547591 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 11:13:15 2023 -0700 Merge branch '2.15' into 2.16 commit 7547591 Author: Tatu Saloranta <[email protected]> Date: Thu May 4 11:12:53 2023 -0700 Mark FasterXML#3895 as fixed (due to another PR/issue) commit ee3b89a Author: ChangYong <[email protected]> Date: Fri May 5 02:09:33 2023 +0900 Fix incorrect comment (FasterXML#3916)
In 2.15 trying to encode records with PropertyAccessor.GETTER = Visibility.NONE will result in an empty object {}.
to resolve that we can set PropertyAccessor.GETTER = Visibility.DEFAULT or others, but that will break every single class serialization that does not have annotations on getter methods.
The behaviour in 2.14 with PropertyAccessor.GETTER = Visibility.NONE is the expected one, with records able to serialize all fields
Is this change something done on purpose? are there alternatives to set the visibility of getters and annotate every class method?
The text was updated successfully, but these errors were encountered: