|
|
|
@@ -132,7 +132,7 @@ public class NewDatasetServiceImpl implements NewDatasetService { |
|
|
|
datasetVo.setIdentifier(repositoryName); |
|
|
|
datasetVo.setId(gitlinIid); |
|
|
|
datasetVo.setOwner((String) userInfo.get("login")); |
|
|
|
datasetVo.setRelativePaths(relatePath+"/dataset"); |
|
|
|
datasetVo.setRelativePaths(relatePath + "/dataset"); |
|
|
|
|
|
|
|
addDatasetSourceToDataVo(datasetVo); |
|
|
|
|
|
|
|
@@ -211,7 +211,7 @@ public class NewDatasetServiceImpl implements NewDatasetService { |
|
|
|
datasetVo.setDescription(newDatasetVo.getDescription()); |
|
|
|
datasetVo.setDataTag(newDatasetVo.getDataTag()); |
|
|
|
datasetVo.setDataType(newDatasetVo.getDataType()); |
|
|
|
datasetVo.setRelativePaths(relatePath+"/dataset"); |
|
|
|
datasetVo.setRelativePaths(relatePath + "/dataset"); |
|
|
|
|
|
|
|
addDatasetSourceToDataVo(datasetVo); |
|
|
|
|
|
|
|
@@ -447,15 +447,27 @@ public class NewDatasetServiceImpl implements NewDatasetService { |
|
|
|
|
|
|
|
if (map != null) { |
|
|
|
List<Map<String, Object>> topics = (List<Map<String, Object>>) map.get("topics"); |
|
|
|
if (topics != null && topics.size() > 0 && datasetTopic.equals(topics.get(1).get("name"))) { |
|
|
|
String datasettag = (String) topics.get(2).get("name"); |
|
|
|
String datasetype = (String) topics.get(3).get("name"); |
|
|
|
datasettag = datasettag.substring("datatag-".length()); |
|
|
|
datasetype = datasetype.substring("datatype-".length()); |
|
|
|
if (StringUtils.isNotEmpty(datasetTagName) && !datasetTagName.toLowerCase().equals(datasettag)) { |
|
|
|
String datasetTopicName = null; |
|
|
|
String datasetTag = null; |
|
|
|
String datasetType = null; |
|
|
|
for (Map<String, Object> topic : topics) { |
|
|
|
String topicName = (String) topic.get("name"); |
|
|
|
if (datasetTopic.equals(topicName)) { |
|
|
|
datasetTopicName = (String) topic.get("name"); |
|
|
|
} |
|
|
|
if (topicName.startsWith("datatag-")) { |
|
|
|
datasetTag = topicName.substring("datatag-".length()); |
|
|
|
} |
|
|
|
if (topicName.startsWith("datatype-")) { |
|
|
|
datasetType = topicName.substring("datatype-".length()); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
if (datasetTopicName != null) { |
|
|
|
if (StringUtils.isNotEmpty(datasetTagName) && !datasetTagName.toLowerCase().equals(datasetTag)) { |
|
|
|
continue; |
|
|
|
} |
|
|
|
if (StringUtils.isNotEmpty(datasetTypeName) && !datasetTypeName.toLowerCase().equals(datasetype)) { |
|
|
|
if (StringUtils.isNotEmpty(datasetTypeName) && !datasetTypeName.toLowerCase().equals(datasetType)) { |
|
|
|
continue; |
|
|
|
} |
|
|
|
newDatasetVo.setDataTag(datasetTagName); |
|
|
|
|