Anti DDOS导入下发增加userRegion.

This commit is contained in:
zhangwenqing
2018-12-21 21:58:32 +08:00
parent cb6b9f152f
commit 69272ba0db
2 changed files with 27 additions and 0 deletions

View File

@@ -2089,6 +2089,12 @@ public abstract class BaseService {
maatCfg.setUserRegion(Constants.APP_ID_REGION + "=" + _cfg.getAppCode()+Constants.USER_REGION_SPLIT+Constants.APP_VIGNORE_USER_REGION_KEY+"=1");
}else if(regionDict.getFunctionId()==408) {// Behavior Identify
maatCfg.setUserRegion(Constants.PROTO_ID_REGION + "=" + _cfg.getAppCode()+Constants.USER_REGION_SPLIT+Constants.APP_VIGNORE_USER_REGION_KEY+"=1");
}else if(regionDict.getFunctionId()==301) {// Anti DDOS
Map umap= new HashMap();
umap.put("protocol", _cfg.getAntiddosProtocol());
umap.put("bps_threadshold", _cfg.getBpsThreadshold());
umap.put("pps_threadshold", _cfg.getPpsThreadshold());
maatCfg.setUserRegion(new Gson().toJson(umap));
}
configCompileList.add(maatCfg);