URL[] classpath = urlList.toArray(new URL[urlList.size()]);
Properties metaData = new Properties();
metaData.setProperty("opStringName", sElem.getOperationalStringName());
metaData.setProperty("serviceName", sElem.getName());
ServiceClassLoader jsbCL = new ServiceClassLoader(ServiceClassLoader.getURIs(classpath),
new ClassAnnotator(exports),
commonCL,
metaData);
/*
ServiceClassLoader jsbCL =
new ServiceClassLoader(classpath, annotator, commonCL);
*/
currentThread.setContextClassLoader(jsbCL);
if(logger.isDebugEnabled()) {
StringBuilder buffer = new StringBuilder();
if(implJARs.length==0) {
buffer.append("<empty>");
} else {
for(int i=0; i<implJARs.length; i++) {
if(i>0)
buffer.append(", ");
buffer.append(implJARs[i].toExternalForm());
}
}
String className = (jsbBundle==null?"<not defined>": jsbBundle.getClassName());
if(logger.isDebugEnabled()) {
logger.debug("Create ServiceClassLoader for {}, classpath {}, codebase {}",
className, buffer.toString(), jsbCL.getClassAnnotation());
}
}
/* Get the servicePolicyFile from the environment. If the
* property has not been set use the policy set for the VM */