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

XmlMapper instantiation fails on branch 2.16 due to databind #4101 #607

Closed
k163377 opened this issue Sep 9, 2023 · 4 comments
Closed

XmlMapper instantiation fails on branch 2.16 due to databind #4101 #607

k163377 opened this issue Sep 9, 2023 · 4 comments

Comments

@k163377
Copy link

k163377 commented Sep 9, 2023

This is a transcription of an issue reported on the jackson-dev mailing list.


The cause is that the following PR added a null check for cache.
https://github.com/FasterXML/jackson-databind/pull/4101/files#diff-25c6303c76a7f05a72cdc35a1271bcc9374db3745d61ab895e7199f050619f7eR168

XmlMapper passes null to the cache, which causes an error.
https://github.com/FasterXML/jackson-dataformat-xml/blame/d1766c9fc014d95b99657b00a0b52e610bd75004/src/main/java/com/fasterxml/jackson/dataformat/xml/deser/XmlDeserializationContext.java#L34

@cowtowncoder
Copy link
Member

Thank for reporting this -- I will see if I can reproduce the problem.

@cowtowncoder
Copy link
Member

Yes, actually have a compilation incompatibility too. Will resolve.

@cowtowncoder
Copy link
Member

Note: this does mean that jackson-dataformat-xml and jackson-databind both need to be 2.16; there is somewhat close coupling due to requirements to keep DefaultDeserializationContext compatible (wrt new withCaches(CacheProvider)), not way around that.
It does not change Jackson project's official stance anyway (all Jackson components SHOULD have same minor version; no other guarantees given), but is against ideal case (wherein "adjacent" minor versions in dependency direction SHOULD work -- xml-format 2.15 should work with databind 2.16 -- but that is not maintained here, due to it not being possible, basically).

@JooHyukKim
Copy link
Member

PR mentioned above : FasterXML/jackson-databind#4101

Just connecting things for easier follow.

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

3 participants