boolean vetoDiscovery = false; // if true, a callback veto'ed the resource - it should not be discovered at all
for (Map.Entry<String, List<String>> entry : callbacks.entrySet()) {
String pluginName = entry.getKey();
List<String> callbackClassNames = entry.getValue();
for (String className : callbackClassNames) {
ResourceDiscoveryCallback callback = pluginComponentFactory.getDiscoveryCallback(pluginName,
className);
try {
Thread.currentThread().setContextClassLoader(callback.getClass().getClassLoader());
callbackResults = callback.discoveredResources(details);// inline in our calling thread - no time outs or anything; hopefully the plugin plays nice
callbackCount++;
if (log.isDebugEnabled()) {
log.debug("Discovery callback [{" + pluginName + "}" + className + "] returned ["
+ callbackResults + "] #invocations=" + callbackCount);
}