Intersection of Modules and Multi-Release JARs
Paul Sandoz
paul.sandoz at oracle.com
Mon Jan 18 16:28:51 UTC 2016
> On 18 Jan 2016, at 17:01, Stephane Epardaud <stef at epardaud.fr> wrote:
>
> Hi,
>
> Well, I can think of at least one use-case where a JDK10 version of a
> module would have different dependencies than JDK9: if the module used
> an external lib for X in JDK9, and then JDK10 incorporated that
> functionality X so that import would no longer be required but the
> module would then import the JDK10 module.
>
> Like what happened for JodaTime and the JDK a while back.
>
> I'm not saying it would justify the additional complexity, but it
> certainly sounds like a plausible use-case. Not one that I'd be in a
> hurry to support in Ceylon either, mind you ;)
>
:-) thanks, an interesting use-case.
Assuming the JodaTime library is not publicly exported (types in the dependent API) and used in a manner that is amenable to maintaining separate classes then i guess it (and it’s dependencies) would have tag along with a "one unit, one set of dependencies” constraint. Otherwise, a version bump is seems necessary.
Thinking ahead it might be possible to augment the module descriptor to state which JDK major versions the dependency is required for, rather than it being specifically versioned. Not sure i like that though.
Paul.
More information about the jigsaw-dev
mailing list