try {
java.net.URI sUri = serverURI == null ? new java.net.URI("hdfs://server") : new java.net.URI(serverURI);
IConfigurationElement[] elementsFor = Platform.getExtensionRegistry().getConfigurationElementsFor("org.apache.hdt.core.hdfsClient");
for (IConfigurationElement element : elementsFor) {
if (sUri.getScheme().equals(element.getAttribute("protocol"))) {
HDFSClient client = (HDFSClient) element.createExecutableExtension("class");
hdfsClientsMap.put(serverURI, new InterruptableHDFSClient(serverURI, client));
}
}
} catch (URISyntaxException e) {
throw new CoreException(new Status(IStatus.ERROR, Activator.BUNDLE_ID, "Invalid server URI", e));