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

Support Gradle 6 version alignment with Jackson Scala module (jackson-module-scala) #478

Open
cowtowncoder opened this issue Nov 15, 2020 · 4 comments

Comments

@cowtowncoder
Copy link
Member

(as background, see FasterXML/jackson-databind#2726)

So, Jackson 2.12 is adding support for Gradle version alignment, using mechanism supported by Gradle 6.
@jjohannes contributed this for other modules and hopefully can help, or at least indicate whether this is feasible with sbt build. There may also be changes needed to jackson-integration-tests test repo, depending on whether metadata may be added.

@pjfanning
Copy link
Member

@cowtowncoder the scala module appears in the main BOM file already. Example: https://oss.sonatype.org/content/repositories/snapshots/com/fasterxml/jackson/jackson-bom/2.12.0-rc2-SNAPSHOT/jackson-bom-2.12.0-rc2-20201103.195011-11.pom

Is the aim to have scala module publish a .module file https://oss.sonatype.org/content/repositories/snapshots/com/fasterxml/jackson/core/jackson-databind/2.12.0-rc2-SNAPSHOT/jackson-databind-2.12.0-rc2-20201115.032546-135.module ?

I haven't found any sbt support or sbt plugin support fo such a file. All in all, I suspect it is best to see if there is community demand for this before expending effort on it.

@cowtowncoder
Copy link
Member Author

This is a new feature for Jackson 2.12, so community demand is bit of a chicken/egg problem. But I filed issue more as likely placeholder, to surface it and maybe get contributions, help. So expectation was not that this is a must-have at this point: if there is no sbt support that would probably be tricky to pull off.

@jjohannes
Copy link

In practice, this is not a problem for the alignment use case, because the Scala module has a dependency to Jackson Core with the same version. The transitive dependencies of Jackson Core (which has the module file) will then take care of the alignment to that version (see FasterXML/jackson-integration-tests#6 for details).

Supporting Gradle Metadata (.module) with sbt and in Gradle's own Scala support is however very interesting in general. I believe we could get to a setup where, on the long run, encoding the Scala version in the name of the module would not be necessary anymore. As with Gradle Metadata you could publish all Jars as different variants under one GAV coordinate.

At Gradle, we just did not get around to push this topic yet. But if someone from the Scala community is happening to read this and interested in this, please feel free to reach out to me.

@cowtowncoder cowtowncoder changed the title Support Gradle 6 version alignment with Scala module too Support Gradle 6 version alignment with Jackson Scala module (jackson-module-scala) Nov 25, 2020
@cowtowncoder
Copy link
Member Author

Sounds good; this issue can remain open so that others might be able to find it.

@cowtowncoder cowtowncoder removed the 2.13 label Feb 4, 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

3 participants