JDeps: detecting offending packages
mandy.chung at oracle.com
Tue Nov 17 03:12:32 UTC 2015
> On Nov 15, 2015, at 9:49 AM, Robert Scholte <rfscholte at apache.org> wrote:
> Ah, I see. Adding usage of java.awt.peer.ComponentPeer did indeed expose an offending package again.
> Just out of interest: will jdeps only detect violations of JDK internal APIs or will it also detect violations on modules? In case I switch from executable jar to executable module it could happen that it breaks due to usage of non-exported packages, right?
jdeps does the static analysis on class level and it will flag any use of JDK internal API regardless modules or non-modules.
The RFE for jdeps would be to take into the module descriptor into account and see what other thing it could report (e.g. missing require public, stale require, etc).
> Op Sat, 14 Nov 2015 17:29:58 +0100 schreef Alan Bateman <Alan.Bateman at oracle.com>:
>> On 14/11/2015 16:05, Mandy Chung wrote:
>>> I think jdeps should continue to flag the critical JDK internal APIs listed in JEP 260 but they are accessible at runtime. I file a bug:
>> I agree and I expect it will be straight-forward once they are moved to their own module.
More information about the jigsaw-dev