除APP feature和ASN IP外的业务增加批量配置取消功能;

修复ddos新增bug;
This commit is contained in:
段冬梅
2019-03-05 17:42:12 +08:00
parent c348697e3b
commit b87f99c852
8 changed files with 70 additions and 15 deletions

View File

@@ -2636,6 +2636,8 @@ public abstract class BaseService {
}
}
}
long start=System.currentTimeMillis();
long end=System.currentTimeMillis();
if (send) {
if(configCompileList.size() > 0) {
ToMaatBean maatBean = new ToMaatBean();
@@ -2644,6 +2646,7 @@ public abstract class BaseService {
maatBean.setCreatorName(UserUtils.getUser().getName());
maatBean.setVersion(Constants.MAAT_VERSION);
maatBean.setOpAction(Constants.INSERT_ACTION);
start=System.currentTimeMillis();
// 调用服务接口下发配置数据
String json = BaseService.gsonToJson(maatBean);
if(configCompileList.size()>10) {
@@ -2652,8 +2655,11 @@ public abstract class BaseService {
logger.info("IP 配置下发配置参数:" + json);
}
// 调用服务接口下发配置
ToMaatResult result = ConfigServiceUtil.postMaatCfg(json);
logger.info("IP 配置下发响应信息:" + result.getMsg());
end=System.currentTimeMillis();
logger.info("IP 配置下发配置耗时:" + (end-start));
}else {
//调用服务接口下发配置数据
String json=gsonToJson(callbackIpList);
@@ -2743,6 +2749,8 @@ public abstract class BaseService {
}
}
long start=System.currentTimeMillis();
long end=System.currentTimeMillis();
if (send && configCompileList.size() > 0) {
ToMaatBean maatBean = new ToMaatBean();
maatBean.setConfigCompileList(configCompileList);
@@ -2750,6 +2758,7 @@ public abstract class BaseService {
maatBean.setCreatorName(UserUtils.getUser().getName());
maatBean.setVersion(Constants.MAAT_VERSION);
maatBean.setOpAction(Constants.INSERT_ACTION);
start=System.currentTimeMillis();
// 调用服务接口下发配置数据
String json = BaseService.gsonToJson(maatBean);
if(configCompileList.size()>10) {
@@ -2760,6 +2769,8 @@ public abstract class BaseService {
// 调用服务接口下发配置
ToMaatResult result = ConfigServiceUtil.postMaatCfg(json);
logger.info("字符串配置下发响应信息:" + result.getMsg());
end=System.currentTimeMillis();
logger.info("字符串配置下发配置耗时:" + (end-start));
}
batchSqlSession.commit();