Legacy mode

Rémi Forax forax at univ-mlv.fr
Sun Sep 11 13:14:12 PDT 2011


On 09/11/2011 09:41 PM, Alan Bateman wrote:
> Rémi Forax wrote:
>>
>> The JDK8 will provide a legacy mode and will have private 
>> dependencies on several libraries
>> that are currently repackaged by adding a package prefix (com.sun.).
>> Now suppose that these libraries are installed as modules,
>> how the JDK will avoid conflicts with versions of these libraries 
>> provided by the application
>> in the classpath ?
> It shouldn't be any different to today. If the JDK has re-packaged an 
> API org.foo into com.sun.internal.org.foo and is using it internally 
> then it's just not going to use the org.foo API that you put on the 
> class path.

I was hoping that modules was a solution to avoid re-packaging.

> Or maybe you are trying to put a newer version of 
> com.sun.internal.org.foo on the class path? That isn't going to be 
> used either as delegation should mean it finds the classes on the boot 
> class path. The usual way to override classes in rt.jar is via 
> -Xbootclasspath/p and that should work exactly the same in jdk8 when 
> running in legacy mode (-Xbootclasspath doesn't of course make sense 
> in modules mode and so won't be allowed).

Why -Xbootclasspath doesn't make sense ?
It's a fast way to patch what you want.

>
> -Alan.

Rémi




More information about the jigsaw-dev mailing list