Skip to content
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

Add ToXmlGenerator.Feature.UNWRAP_ROOT_OBJECT_NODE (to avoid root ObjectNode wrapper element) #441

Closed
cowtowncoder opened this issue Dec 10, 2020 · 0 comments

Comments

@cowtowncoder
Copy link
Member

Jackson 2.12 improved handling of JsonNode on reader-side (f.ex see #205, #403 and #405).
But when trying to serialize JsonNode we still get an unnecessary <ObjectNode> wrapper.
This should be peeled away; although for backwards-compatibility we may want to put this behind a ToXmlGenerator.Feature (default setting to be debated).

It may also make sense consider "unwrapping" of other types, depending on how implementation turns out (may end up with 2 features, one for JsonNode, other for the rest -- if others are even feasible).

cowtowncoder added a commit that referenced this issue Dec 10, 2020
cowtowncoder added a commit that referenced this issue Jul 4, 2021
@cowtowncoder cowtowncoder changed the title Serialization of JsonNode adds unnecessary wrapper (ObjectNode) Add ToXmlGenerator.Feature.UNWRAP_ROOT_OBJECT_NODE (to avoid root ObjectNode wrapper element) Jul 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant