feat: There is no way the MQ conf
This commit is contained in:
@@ -44,7 +44,7 @@ public class SendDoneMQService {
|
||||
value = @Queue(value = "createMQDone_SQ_GSAR", durable = "true"),
|
||||
exchange = @Exchange(value = "sendDone-exchange_MQ_GSAR", ignoreDeclarationExceptions = "true"),
|
||||
key = "sendDone-key_MQ_GSAR"))
|
||||
public void createMQ(NotifyTodoSendContext object, Message message, Channel channel) throws Exception{
|
||||
public void createMQDone(NotifyTodoSendContext object, Message message, Channel channel) throws Exception{
|
||||
try{
|
||||
try{
|
||||
insertOrUpdateInfo(object);
|
||||
@@ -84,24 +84,22 @@ public class SendDoneMQService {
|
||||
}
|
||||
|
||||
public void restartSendMq(NotifyTodoSendContext object) throws Exception{
|
||||
SendTodoLog sendTodoLog = new SendTodoLog();
|
||||
QueryWrapper wrapper = new QueryWrapper();
|
||||
wrapper.eq("TODO_ID",object.getModelId());
|
||||
wrapper.eq("MSG_TYPE","1");
|
||||
List<SendTodoLog> list = sendTodoLogMapper.selectList(wrapper);
|
||||
if(!list.isEmpty()){
|
||||
sendTodoLog = list.get(0);
|
||||
}
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyy-MM-dd HH:mm:ss");
|
||||
if(sendTodoLog != null){
|
||||
if(!list.isEmpty()){
|
||||
SendTodoLog sendTodoLog = list.get(0);
|
||||
int againNumNew = Integer.valueOf(sendTodoLog.getErrNum());
|
||||
if(againNumNew >= 6){
|
||||
// 发送待办 或 发送给管理员邮箱
|
||||
logger.info("发送失败9次,发送给管理员邮箱");
|
||||
logger.info("发送失败6次,发送给管理员邮箱");
|
||||
|
||||
}else {
|
||||
restSendDoneTodo(object, sdf, sendTodoLog, againNumNew);
|
||||
}
|
||||
|
||||
}else {
|
||||
sendTodoSave(object, sdf, "3");
|
||||
}
|
||||
|
||||
+3
-1
@@ -3,13 +3,15 @@ package com.ydw.bat.wkflow.business_oa.webService.todoContent;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* @Description: TODO
|
||||
* @author: super_liu
|
||||
* @date: 2021年09月08日 15:05
|
||||
*/
|
||||
@Data
|
||||
public class NotifyTodoSendContext {
|
||||
public class NotifyTodoSendContext implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "标识待办来源的系统")
|
||||
private String appName;
|
||||
|
||||
Reference in New Issue
Block a user