You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add support for @JsonMerge to allow "deep update" #1399
Currently existing values of properties are not taken into consideration, with the rare case of "setterless-getters" where this is done for Collection types if no setter exists.
But it would be useful to allow this for Maps and POJOs as well.
which would specify default merge/no-merge settings for properties of specified type.
It would probably also make sense to allow setting fully global default, similar to ability to set "serializationInclusion" global defaults (with JsonInclude.Value).
Reacted by Romain Fromi, Reinaldo Besen, Christian Marsch, Don Han and Vasily Kumaev
changed the title [-]Add support for `@JsonSetter(merge=OptBoolean.TRUE`) to allow "deep update" [/-][+]Add support for `@JsonMerge` to allow "deep update" [/+]on Feb 1, 2017
Activity
Initial version of merging-property-deser (#1399)
Mark #1399 completed; some aspects remain, but initial implementation…
cowtowncoder commentedon Oct 27, 2016
Initial implementation now exists, supporting POJOs,
Collections,Maps, reference types.heruan commentedon Jan 3, 2017
Any docs on how to test this?
cowtowncoder commentedon Jan 6, 2017
@heruan at this point the best way I think is to search for unit tests with
@JsonSetter(merge=.[-]Add support for `@JsonSetter(merge=OptBoolean.TRUE`) to allow "deep update" [/-][+]Add support for `@JsonMerge` to allow "deep update" [/+]Tetradeus commentedon Apr 7, 2017
Wouldn't it be nice to have an option to enable setting null values at merge path ? Ref #1437
What if I really want to be able to set null for loc ? assertNull(config.loc);
Thanks for your reply.
cowtowncoder commentedon Apr 7, 2017
@Tetradeus Please file a new issue; this one is closed. We can discuss details as part of that.