} catch (URISyntaxException e) {
}
}
if (ResourcesPlugin.getWorkspace().getRoot().getProject(name).exists())
throw new CoreException(new Status(IStatus.ERROR, Activator.BUNDLE_ID, "Project with name '" + name + "' already exists"));
HDFSServer hdfsServer = HadoopFactory.eINSTANCE.createHDFSServer();
hdfsServer.setName(name);
hdfsServer.setUri(hdfsURI.toString());
hdfsServer.setLoaded(true);
if (userId != null)
hdfsServer.setUserId(userId);
if (groupIds != null)
for (String groupId : groupIds)
hdfsServer.getGroupIds().add(groupId);
getHdfsServers().add(hdfsServer);
HadoopManager.INSTANCE.saveServers();
uriToServerMap.put(hdfsServer.getUri(), hdfsServer);
serverToProjectMap.put(hdfsServer, name);
projectToServerMap.put(name, hdfsServer);
createIProject(name, hdfsURI);
return hdfsServer;
}