use of org.talend.core.hadoop.IHadoopClusterService in project tdi-studio-se by Talend.
the class DatabaseTypeFilter method getHadoopSubMultiRepTypeProcessor.
private IRepositoryTypeProcessor getHadoopSubMultiRepTypeProcessor(String[] repTypes) {
IHadoopClusterService hadoopClusterService = HadoopRepositoryUtil.getHadoopClusterService();
if (hadoopClusterService != null) {
List<String> repTypeList = new ArrayList<String>();
Map<String, Object> attributes = new HashMap<String, Object>();
for (String repType : repTypes) {
Map<String, Object> attr = parseAttributes(repType);
if (attr == null) {
repTypeList.add(repType);
} else {
attributes.putAll(attr);
}
}
IRepositoryTypeProcessor processor = hadoopClusterService.getHadoopSubMultiRepTypeProcessor(repTypeList.toArray(new String[0]));
processor.setAttributes(attributes);
return processor;
}
return null;
}
Aggregations