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 17363 - Elaborate difference between TopManager and Lookup
Summary: Elaborate difference between TopManager and Lookup
Status: VERIFIED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Lookup (show other bugs)
Version: 3.x
Hardware: PC Linux
: P3 blocker (vote)
Assignee: Jaroslav Tulach
URL:
Keywords:
Depends on:
Blocks: 17246
  Show dependency tree
 
Reported: 2001-11-07 09:50 UTC by _ pkuzel
Modified: 2008-12-22 22:07 UTC (History)
0 users

See Also:
Issue Type: TASK
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ pkuzel 2001-11-07 09:50:48 UTC
http://openide.netbeans.org/issues/show_bug.cgi?id=17246 showed that:

TopManager.getDefault().systemClassLoader() 

is more deadlock ressistant than:

Lookup.getDefault().lookup(newLookup.Templte(ClassLoader.class)).allInstances()

The second approach is preffered so it should be improved as it should be able
to replace the first one in all use cases.
Comment 1 Jaroslav Tulach 2001-11-13 14:01:42 UTC
TopManager.getDefault ().systemClassLoader () is the same as
Lookup.getDefault ().lookup (ClassLoader.class)

Getting result and calling allInstances is more dangerous. Ok?
Comment 2 _ pkuzel 2001-11-13 14:14:36 UTC
It is the same, at least by current implementation.