|
@@ -134,8 +134,8 @@ public class RecallService implements ApplicationContextAware {
|
|
|
if (CollectionUtils.isEmpty(categoryList)) {
|
|
|
return;
|
|
|
}
|
|
|
- Map<String, String> categoryMap = categoryList.stream().collect(
|
|
|
- Collectors.toMap(CrawlerMetaArticle::getUniqueIndex, CrawlerMetaArticle::getCategory));
|
|
|
+ Map<String, List<String>> categoryMap = categoryList.stream().collect(Collectors.groupingBy(CrawlerMetaArticle::getChannelContentId,
|
|
|
+ Collectors.mapping(CrawlerMetaArticle::getCategory, Collectors.toList())));
|
|
|
for (Content content : contentList) {
|
|
|
String md5 = articleMd5Map.get(content.getId());
|
|
|
content.setCategory(categoryMap.get(md5));
|