|
@@ -243,6 +243,7 @@ public class ContentServiceImpl implements ContentService {
|
|
|
"accountName:%s \n",
|
|
"accountName:%s \n",
|
|
|
planAccount.getPlanId(), planAccount.getPlanName(), planAccount.getAccountId(), planAccount.getAccountName());
|
|
planAccount.getPlanId(), planAccount.getPlanName(), planAccount.getAccountId(), planAccount.getAccountName());
|
|
|
LarkRobotUtil.sendMessage(message);
|
|
LarkRobotUtil.sendMessage(message);
|
|
|
|
|
+ triggerRebuildRecommend(planAccount, articleSortRequest);
|
|
|
return new ArrayList<>();
|
|
return new ArrayList<>();
|
|
|
}
|
|
}
|
|
|
ArticleSortResponseData data = articleSortResponse.getData();
|
|
ArticleSortResponseData data = articleSortResponse.getData();
|
|
@@ -258,16 +259,18 @@ public class ContentServiceImpl implements ContentService {
|
|
|
param.setFilterSortContentList(list);
|
|
param.setFilterSortContentList(list);
|
|
|
aigcService.filterSortContents(param);
|
|
aigcService.filterSortContents(param);
|
|
|
}
|
|
}
|
|
|
- if (CollectionUtils.isEmpty(articleSortResponse.getData().getRank_list())
|
|
|
|
|
- || articleSortResponse.getData().getRank_list().size() < (planAccount.getPublishPreMinNum() - excludeContentSum)) {
|
|
|
|
|
- log.info("rank_list = {}", articleSortResponse.getData().getRank_list());
|
|
|
|
|
|
|
+ List<PublishArticleData> rankList = data.getRank_list();
|
|
|
|
|
+ if (CollectionUtils.isEmpty(rankList)
|
|
|
|
|
+ || rankList.size() < (planAccount.getPublishPreMinNum() - excludeContentSum)) {
|
|
|
|
|
+ int rankListSize = CollectionUtils.isEmpty(rankList) ? 0 : rankList.size();
|
|
|
|
|
+ log.info("rank_list = {}", rankList);
|
|
|
String message = String.format("排序结果不足 \n" +
|
|
String message = String.format("排序结果不足 \n" +
|
|
|
"planId:%s \n" +
|
|
"planId:%s \n" +
|
|
|
"planName:%s \n" +
|
|
"planName:%s \n" +
|
|
|
"accountId:%s \n" +
|
|
"accountId:%s \n" +
|
|
|
"accountName:%s \n" +
|
|
"accountName:%s \n" +
|
|
|
"num:%s",
|
|
"num:%s",
|
|
|
- planAccount.getPlanId(), planAccount.getPlanName(), planAccount.getAccountId(), planAccount.getAccountName(), articleSortResponse.getData().getRank_list().size());
|
|
|
|
|
|
|
+ planAccount.getPlanId(), planAccount.getPlanName(), planAccount.getAccountId(), planAccount.getAccountName(), rankListSize);
|
|
|
LarkRobotUtil.sendMessage(message);
|
|
LarkRobotUtil.sendMessage(message);
|
|
|
// 清除待发布缓存,成功后异步触发一次 /recommend 重建数据
|
|
// 清除待发布缓存,成功后异步触发一次 /recommend 重建数据
|
|
|
triggerRebuildRecommend(planAccount, articleSortRequest);
|
|
triggerRebuildRecommend(planAccount, articleSortRequest);
|
|
@@ -277,7 +280,7 @@ public class ContentServiceImpl implements ContentService {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
- * 排序结果不足时调用:
|
|
|
|
|
|
|
+ * 排序结果为空或不足时调用:
|
|
|
* 1. 调用 /deleteGzhWaiting 清除当前 planId + accountId 的待发布缓存
|
|
* 1. 调用 /deleteGzhWaiting 清除当前 planId + accountId 的待发布缓存
|
|
|
* 2. 清除成功后异步触发一次 /recommend 重新生成排序数据(不关心返回结果)
|
|
* 2. 清除成功后异步触发一次 /recommend 重新生成排序数据(不关心返回结果)
|
|
|
*/
|
|
*/
|