社交应用服务器IP所属分组非第一次下发时,无需再次下发具体IP列表信息,只下发groupId与compileId,以及业务配置其他基础信息即可。
This commit is contained in:
@@ -275,7 +275,7 @@ public class AppCfgService extends CrudService<AppCfgDao,AppIdCfg> {
|
||||
List<AppComplexKeywordCfg> complexList = new ArrayList();
|
||||
List<SpecificServiceHostCfg> hostList =new ArrayList();
|
||||
List<BaseIpCfg> areaList = new ArrayList();
|
||||
ConfigGroupInfo group = new ConfigGroupInfo();
|
||||
ConfigGroupInfo group = null;
|
||||
|
||||
|
||||
Gson gson=new GsonBuilder().disableHtmlEscaping()
|
||||
@@ -289,24 +289,38 @@ public class AppCfgService extends CrudService<AppCfgDao,AppIdCfg> {
|
||||
if(Constants.AUDIT_YES==entity.getIsAudit().intValue()){//审核通过
|
||||
if(StringUtil.isEmpty(featuresTableList)){
|
||||
SpecificServiceCfg protocol = specificServiceCfgDao.getBySpecServiceId(appCfg.getAppId().intValue());
|
||||
SpecificServiceHostCfg hostCfg = new SpecificServiceHostCfg();
|
||||
hostCfg.setSpecServiceId(protocol.getSpecServiceId());
|
||||
hostList = specificServiceHostCfgDao.findSpecHostList(hostCfg);
|
||||
group = specificServiceCfgDao.getConfigGroupInfoByGroupId(protocol.getGroupId());
|
||||
//featuresTableList为空的时候,该service只有特定服务IP一个配置表
|
||||
ServiceConfigInfo serviceCfg=serviceConfigInfoDao.findSysServiceConfigInfo(appCfg.getServiceId());
|
||||
for(SpecificServiceHostCfg host:hostList){
|
||||
SpecificServiceCfg specServiceCfg = specificServiceCfgDao.getBySpecServiceId(host.getSpecServiceId());
|
||||
host.setProtocolId(0);
|
||||
host.setGroupId(specServiceCfg.getGroupId());
|
||||
if(StringUtil.isEmpty(serviceCfg)){
|
||||
host.setMaatTable("DF_PROTOCOL_APP");
|
||||
if(group==null){
|
||||
throw new RuntimeException("配置审核失败,未获取社交应用服务器IP所属分组信息");
|
||||
}else{
|
||||
if(group.getIsIssued()==0){
|
||||
//如果分组信息尚未下发,则下发IP
|
||||
group.setGroupId(protocol.getGroupId());
|
||||
group.setIsIssued(1);
|
||||
SpecificServiceHostCfg hostCfg = new SpecificServiceHostCfg();
|
||||
hostCfg.setSpecServiceId(protocol.getSpecServiceId());
|
||||
hostList = specificServiceHostCfgDao.findSpecHostList(hostCfg);
|
||||
|
||||
for(SpecificServiceHostCfg host:hostList){
|
||||
SpecificServiceCfg specServiceCfg = specificServiceCfgDao.getBySpecServiceId(host.getSpecServiceId());
|
||||
host.setProtocolId(0);
|
||||
host.setGroupId(specServiceCfg.getGroupId());
|
||||
if(StringUtil.isEmpty(serviceCfg)){
|
||||
host.setMaatTable("DF_PROTOCOL_APP");
|
||||
}else{
|
||||
host.setMaatTable(serviceCfg.getMaatTable());
|
||||
}
|
||||
}
|
||||
}else{
|
||||
host.setMaatTable(serviceCfg.getMaatTable());
|
||||
SpecificServiceHostCfg host = new SpecificServiceHostCfg();
|
||||
host.setGroupId(protocol.getGroupId());
|
||||
hostList.add(host);
|
||||
}
|
||||
|
||||
group.setGroupId(specServiceCfg.getGroupId());
|
||||
group.setIsIssued(1);
|
||||
}
|
||||
|
||||
|
||||
//生效区域列表信息
|
||||
if(appCfg.getIsAreaEffective()==1){
|
||||
if(StringUtil.isEmpty(appCfg.getAreaEffectiveIds())){
|
||||
|
||||
Reference in New Issue
Block a user