This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 22508

Summary: ProxyClassLoader should warn re. ambiguous delegation
Product: platform Reporter: Jesse Glick <jglick>
Component: Module SystemAssignee: Petr Nejedly <pnejedly>
Status: RESOLVED DUPLICATE    
Severity: blocker CC: eakle, jtulach, pnejedly
Priority: P4    
Version: 3.x   
Hardware: All   
OS: All   
Issue Type: ENHANCEMENT Exception Reporter:
Bug Depends on: 30971    
Bug Blocks:    

Description Jesse Glick 2002-04-16 17:01:30 UTC
It would be nice if when a ProxyClassLoader is
asked to load some class which could be found in
more than one parent classloader, a warning was
logged. Typically this would mean that two
versions of a library L coexist at once in the VM
- say, L1 and L2 - and some module accidentally
depends on both - say, M1 on L1, M2 on L2, M3 on
M1 and M2 - and an attempt is made to load a class
in the L namespace from M3. In this case the
result is arbitrary, which could be dangerous.

It may be that the warning can only be logged in
the case that both L1 and L2 have done some
classloading in the package in question by the
time that M3 tries to load from that package
(because of the package shortcut optimizations in
ProxyClassLoader).
Comment 1 Marek Grummich 2002-07-22 08:44:45 UTC
Target milestone was changed from '3.4' to TBD.
Comment 2 Marek Grummich 2002-07-22 09:17:15 UTC
Target milestone was changed from '3.4' to TBD.
Comment 3 Jesse Glick 2005-07-29 22:14:49 UTC
Probably related to what Yarda is working on at the moment.
Comment 4 Jaroslav Tulach 2007-09-03 10:50:23 UTC
Petr, I guess you can now implement this pretty easily.
Comment 5 Jesse Glick 2008-06-11 03:02:18 UTC

*** This issue has been marked as a duplicate of 118020 ***