|
@@ -54,6 +54,9 @@ public class TaskService {
|
|
|
public void sendMq() {
|
|
|
checkCount();
|
|
|
List<MqSendLog> mqSendLogs = mqSendLogService.getNoSendMsg();
|
|
|
+ if(mqSendLogs.isEmpty()){
|
|
|
+ return;
|
|
|
+ }
|
|
|
log.info("未分配的mq队列数:{}",mqSendLogs.size());
|
|
|
List<MqQueueConfig> queueConfigList = queueConfigService.list();
|
|
|
for (MqQueueConfig mqQueueConfig : queueConfigList) {
|
|
@@ -146,10 +149,10 @@ public class TaskService {
|
|
|
|
|
|
public void checkDelEcs() {
|
|
|
List<MqEcs> mqEcsList = mqEcsService.getScalingNotStopList();
|
|
|
- log.info("启动中的弹性伸缩数量为:{}",mqEcsList.size());
|
|
|
if(mqEcsList.isEmpty()){
|
|
|
return;
|
|
|
}
|
|
|
+ log.info("启动中的弹性伸缩数量为:{}",mqEcsList.size());
|
|
|
HashMap<String,MqQueueConfig> queueMap = queueConfigService.getQueueMap();
|
|
|
HashMap<Integer,MqScalingConfig> scalingMap = mqScalingConfigService.getIdMap();
|
|
|
for (MqEcs mqEcs : mqEcsList) {
|
|
@@ -177,10 +180,10 @@ public class TaskService {
|
|
|
@Async
|
|
|
public void delEcsList() {
|
|
|
try {
|
|
|
- log.info("delEcsList--关闭弹性伸缩数量:{}",delList.size());
|
|
|
if(delList.isEmpty()){
|
|
|
return;
|
|
|
}
|
|
|
+ log.info("delEcsList--关闭弹性伸缩数量:{}",delList.size());
|
|
|
DelEcsVo take = delList.poll();
|
|
|
if(take == null){
|
|
|
return;
|