提交 65d82936 作者: 925993793@qq.com

清空历史数据接口-增加删除中间库数据逻辑以及其他问题处理

上级 a034aaff
......@@ -15,7 +15,7 @@ import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
@Configuration
public class WebConfigure implements WebMvcConfigurer {
@Value("${jeecg.shiro,excludeUrls:}")
@Value("${jeecg.shiro.excludeUrls:}")
private String ALLOW_URL;
//服务部署环境 clb:克虏宝 yjzx:研究中心
@Value("${server.profiles:clb}")
......
......@@ -20,4 +20,14 @@ public interface RemoteModelService {
*/
@GetMapping("/modelArrange/clbBiz/detailSubjectDataWithFlow")
String reScoreRequest(@RequestParam("subjectId") String subjectId,@RequestParam("flowId") String flowId, @RequestHeader HttpHeaders headers);
/**
* 重新打分请求
*
* @param subjectId 专题id
* @author lkg
* @date 2025/2/7
*/
@GetMapping("/modelArrange/clbBiz/delMiddelDataBySubjectId")
String removeMiddleDataRequest(@RequestParam("subjectId") String subjectId,@RequestHeader HttpHeaders headers);
}
......@@ -10,12 +10,16 @@ import com.zzsn.event.constant.Constants;
import com.zzsn.event.entity.*;
import com.zzsn.event.enums.CodePrefixEnum;
import com.zzsn.event.es.EsService;
import com.zzsn.event.feign.api.RemoteModelService;
import com.zzsn.event.service.*;
import com.zzsn.event.util.CodeGenerateUtil;
import com.zzsn.event.util.EsOpUtil;
import com.zzsn.event.util.PythonUtil;
import com.zzsn.event.util.user.UserUtil;
import com.zzsn.event.util.user.UserVo;
import com.zzsn.event.vo.*;
import com.zzsn.event.vo.es.SpecialInformation;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.lang3.StringUtils;
import org.elasticsearch.index.query.BoolQueryBuilder;
......@@ -23,6 +27,7 @@ import org.elasticsearch.index.query.QueryBuilders;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.http.HttpHeaders;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
......@@ -36,6 +41,7 @@ import java.util.stream.Collectors;
* @author lkg
* @date 2025/1/9
*/
@Slf4j
@Service
public class SubjectSimpleServiceImpl implements SubjectSimpleService {
......@@ -74,6 +80,8 @@ public class SubjectSimpleServiceImpl implements SubjectSimpleService {
private CodeGenerateUtil codeGenerateUtil;
@Autowired
private PythonUtil pythonUtil;
@Autowired
private RemoteModelService remoteModelService;
@Value("${clb.subject.default.processing.advanceMonth}")
private Integer defaultAdvanceMonth;
......@@ -434,6 +442,13 @@ public class SubjectSimpleServiceImpl implements SubjectSimpleService {
boolQuery.must(QueryBuilders.termQuery("subjectId.keyword", subjectId));
esOpUtil.docDeleteByQuery(Constants.SUBJECT_INDEX, boolQuery);
});
UserVo loginUser = UserUtil.getLoginUser();
CompletableFuture.runAsync(() ->{
HttpHeaders headers = new HttpHeaders();
headers.set("loginUser", JSON.toJSONString(loginUser));
remoteModelService.removeMiddleDataRequest(subjectId, headers);
log.info("专题-{},删除中间库数据请求发送成功", subjectId);
});
}
//目标集合按照另一个集合的顺序排序
......
......@@ -109,9 +109,9 @@ public class InfoDataSearchCondition {
//排序参数
//排序字段
private String column;
private String column = "publishDate";
//排序方式 asc/desc
private String order;
private String order = "desc";
//置顶排序是否起效(1-是;0-否)
private Integer topSortValid = 0;
......
......@@ -161,7 +161,7 @@ python:
clearDuplicateHistoryUrl: http://1.95.13.40:8080/subject/delete_history_data
jeecg:
shiro:
excludeUrls:
excludeUrls: /info/subjectPageList
kafka:
topic:
subject:
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论