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

Upgrade to Jackson 2.12.x #632

Closed
gheine opened this issue Jun 23, 2021 · 13 comments · Fixed by #740
Closed

Upgrade to Jackson 2.12.x #632

gheine opened this issue Jun 23, 2021 · 13 comments · Fixed by #740

Comments

@gheine
Copy link

gheine commented Jun 23, 2021

Jackson 2.12.0 was released in November 2020 (latest version is 2.12.3). Would it be possible to upgrade play-json before the 2.10.0 GA relase?

@SethTisue
Copy link
Member

@marcospereira would a pull request on this be welcome, or do compatibility constraints preclude it?

@marcospereira
Copy link
Member

Hum, I'm not sure we can jump directly to that version. Play tries to use the same version used by Akka 2.6, and the latest release there uses Jackson 2.11:

https://github.com/akka/akka/blob/ceac67050199fb3683115011aa793905e64a73aa/project/Dependencies.scala#L28

Are Jackson 2.11 and 2.12 binary compatible?

@gheine
Copy link
Author

gheine commented Jun 23, 2021

Play tries to use the same version used by Akka 2.6, and the latest release there uses Jackson 2.11:

Play-json is independent of play though (both in version and release cycles) and doesn't depend on akka?

Are Jackson 2.11 and 2.12 binary compatible?

Not sure, I would assume nothing.

@marcospereira
Copy link
Member

It is independent, but we usually try to keep the projects in sync to avoid having too many branches to maintain and backport fixes. But I'm not strongly opposed to the update.

@mkurz, what do you think?

@mkurz
Copy link
Member

mkurz commented Jul 12, 2021

@marcospereira IMHO we should not upgrade to 2.12.x in play-json yet. Like you said, we should keep versions in sync with akka and Play, which both in latest versions use jackson 2.11.4. Who knows which problems could arise for Play/akka projects when a newer jackson version is on the classpath... Also, people which use sbt 1.5 would probably get an error because of the incompatible versions (because of sbt's new version conflict behaviour). Plus people would open issues in the Play repo blaming Play breaking their apps...

@gheine If you are using play-json standalone, you can just override the jackson dependency. That should work for you or not?

@mkurz
Copy link
Member

mkurz commented Jul 12, 2021

Also see this discussion with Ignasi: playframework/playframework#10541 (comment)

@gheine
Copy link
Author

gheine commented Jul 14, 2021

@gheine If you are using play-json standalone, you can just override the jackson dependency. That should work for you or not?

@mkurz will this not cause binary incompatibilities at runtime, if play-json is compiled against 2.11.x and at runtime I provide a 2.12.x jar? Case in point the comment in the playframework issue you linked:

We can't upgrade to 2.12.x because that's not compatible with 2.11

@mkurz
Copy link
Member

mkurz commented Jul 14, 2021

@gheine Yeah, that could be a problem of course. I am not sure if Jackson 2.11 and 2.12 are binary compatible, so there definitely is a risk if you override the dependency. Is there a feature or bugfix in 2.12 that makes you want to upgrade Jjackson?

@gheine
Copy link
Author

gheine commented Jul 19, 2021

@mkurz the AWS Java SDK recently upgraded from Jackson 2.11 to 2.12, see https://aws.amazon.com/blogs/developer/aws-sdk-for-java-version-1-12/, and since we're using them together with play-json, we're stuck on the old version.

@acando86
Copy link

With jackson-databind CVE https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-36518 unlikely to be backported to 2.11/2.12 as per comment here FasterXML/jackson-databind#2816 (comment) and given the binary incompatibilities between the versions, is there any plan to bring play-json to a more recent version of jackson-databind?

@mkurz
Copy link
Member

mkurz commented Mar 15, 2022

@acando86 Please see above comments, we are sticking with the jackson version that akka is using. You might want to file an issue in the akka repository.

@mkurz
Copy link
Member

mkurz commented Apr 5, 2022

Please have a look my comment in #740, for the next major release IMHO it now makes sense to upgrade to latest Jackson for play-json and play itself.
For CVE-2020-36518 however I think users should upgrade the dependency themselves... Since I don't want to introduce breaking changes into production apps... So everyone has to test carefully. I will write an announcement about the CVE-2020-36518 in the GitHub Discussions soon.

@mkurz mkurz linked a pull request Apr 5, 2022 that will close this issue
@mkurz
Copy link
Member

mkurz commented Apr 6, 2022

Please see playframework/playframework#11222 how to upgrade Jackson to latest version in your Play application.
The pull request to upgrade to latest jackson in play-json's main branch can be found here: #740

@mkurz mkurz closed this as completed Apr 6, 2022
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

Successfully merging a pull request may close this issue.

5 participants