1:整理下发或取消配置时返回的异常信息
2:整理业务类型142的redisdb,表等关系
This commit is contained in:
@@ -71,7 +71,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
.getUnMaatTableName(service);
|
||||
if (maatTableName == null) {
|
||||
throw new RuntimeException(
|
||||
"后台错误:未从业务类型和表对应关系中,找到非maat配置业务类型:" + service
|
||||
"未从业务类型和表对应关系中,找到非maat配置业务类型:" + service
|
||||
+ "对应的真实表名");
|
||||
} else {
|
||||
keyBF.append(maatTableName);
|
||||
@@ -146,7 +146,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException(
|
||||
"后台错误:无法从maat.xml中获取业务类型" + service + "对应的规则,请检查业务类型是否正确");
|
||||
"无法从maat.xml中获取业务类型" + service + "对应的规则,请检查业务类型是否正确");
|
||||
}
|
||||
}
|
||||
transaction.incrBy("MAAT_VERSION", 1l);
|
||||
@@ -155,11 +155,10 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
count++;
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException(
|
||||
"后台错误:向" + redisDBIndex + "号redis库中添加配置时,未发现对应的配置信息,请检查配置参数是否正确");
|
||||
throw new RuntimeException("向" + redisDBIndex + "号redis库中添加配置时,未发现对应的配置信息,请检查配置参数是否正确");
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:redis数据库编号:" + redisDBIndex + "不正确,请检查数据库编号");
|
||||
throw new RuntimeException("redis数据库编号:" + redisDBIndex + "不正确,请检查数据库编号");
|
||||
}
|
||||
}
|
||||
if (count == configMap.size()) {
|
||||
@@ -169,13 +168,14 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
transaction.discard();
|
||||
}
|
||||
} catch (JedisConnectionException e) {
|
||||
// transaction.discard();
|
||||
logger.error("后台错误:连接redis异常,保存非maat类配置失败,{}", e.getMessage());
|
||||
throw new RuntimeException("后台错误:连接redis异常,保存非maat类配置失败", e);
|
||||
String error = "后台错误:连接redis异常,保存非maat类配置失败," + e.getMessage();
|
||||
logger.error(error);
|
||||
throw new RuntimeException(error, e);
|
||||
} catch (Exception e) {
|
||||
transaction.discard();
|
||||
logger.error("后台错误:保存非maat类配置发生了异常,{}", e.getMessage());
|
||||
throw new RuntimeException("后台错误:保存非maat类配置发生了异常", e);
|
||||
String error = "后台错误:保存非maat类配置发生了异常," + e.getMessage();
|
||||
logger.error(error);
|
||||
throw new RuntimeException(error, e);
|
||||
} finally {
|
||||
// 释放连接到连接池
|
||||
JedisUtils.returnResource(resource);
|
||||
@@ -289,11 +289,11 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:redis数据库编号:" + redisDBIndex + "不正确,请检查数据库编号");
|
||||
throw new RuntimeException("redis数据库编号:" + redisDBIndex + "不正确,请检查数据库编号");
|
||||
}
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:参数不能为空");
|
||||
throw new RuntimeException("参数不能为空");
|
||||
}
|
||||
|
||||
}
|
||||
@@ -339,7 +339,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
keyBF.append(keyVal);
|
||||
} else {
|
||||
throw new RuntimeException(
|
||||
"后台错误:未从map中获取到" + keyStr + "的值,无法拼接redisKey,请检查数据是否正确");
|
||||
"未从map中获取到" + keyStr + "的值,无法拼接redisKey,请检查数据是否正确");
|
||||
}
|
||||
} else if (!StringUtils.isEmpty(keyStr) && keyStr.trim().startsWith("{")) {
|
||||
keyStr = keyStr.trim().replace("{", "").replace("}", "");
|
||||
@@ -348,8 +348,8 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
String maatTableName = ServiceAndRDBIndexReal.getMaatTableName(
|
||||
service, 10, argTableName == null ? null : argTableName);
|
||||
if (maatTableName == null) {
|
||||
throw new RuntimeException("后台错误:未从业务类型和表对应关系中,找到业务类型:"
|
||||
+ service + ",配置类型:10,对应的真实表名");
|
||||
throw new RuntimeException(
|
||||
"未从业务类型和表对应关系中,找到业务类型:" + service + ",配置类型:10,对应的真实表名");
|
||||
} else {
|
||||
keyBF.append(maatTableName);
|
||||
}
|
||||
@@ -373,7 +373,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
// valStr.toLowerCase().equals("action")
|
||||
// &&!valStr.toLowerCase().equals("user_region") &&type==10) {
|
||||
throw new RuntimeException(
|
||||
"后台错误:未从map中获取到" + valStr + "的值,无法拼接redisValue,请检查数据是否正确");
|
||||
"未从map中获取到" + valStr + "的值,无法拼接redisValue,请检查数据是否正确");
|
||||
|
||||
}
|
||||
} else if (valStr.equals("\t")) {// xml中是字符串的\t这里判断的时候需要转义为\\t,但是添加的时候需要添加\t不是\\t
|
||||
@@ -398,11 +398,11 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException(
|
||||
"后台错误:向" + redisStatisticsRealDBIndex + "号redis库中添加配置时,未发现对应的配置信息,请检查配置参数是否正确");
|
||||
"向" + redisStatisticsRealDBIndex + "号redis库中添加配置时,未发现对应的配置信息,请检查配置参数是否正确");
|
||||
}
|
||||
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:redis数据库编号:" + redisStatisticsRealDBIndex + "不正确,请检查数据库编号");
|
||||
throw new RuntimeException("redis数据库编号:" + redisStatisticsRealDBIndex + "不正确,请检查数据库编号");
|
||||
}
|
||||
break;// configMap中所有的value都是相同的,在记录配置新增或者取消时只记录一次即可
|
||||
}
|
||||
@@ -437,7 +437,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
argTableName == null ? null : argTableName);
|
||||
if (maatTableName == null) {
|
||||
throw new RuntimeException(
|
||||
"后台错误:未从业务类型和表对应关系中,找到业务类型:" + service + ",配置类型:" + type + ",对应的真实表名");
|
||||
"未从业务类型和表对应关系中,找到业务类型:" + service + ",配置类型:" + type + ",对应的真实表名");
|
||||
} else {
|
||||
keyBF.append(maatTableName);
|
||||
}
|
||||
@@ -496,12 +496,11 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
Integer.valueOf(maatVersionStr) + 1);
|
||||
count++;
|
||||
} else {
|
||||
throw new RuntimeException(
|
||||
"后台错误:向" + redisDBIndex + "号redis库中添加配置时,未发现对应的配置信息,请检查配置参数是否正确");
|
||||
throw new RuntimeException("向" + redisDBIndex + "号redis库中添加配置时,未发现对应的配置信息,请检查配置参数是否正确");
|
||||
}
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:redis数据库编号:" + redisDBIndex + "不正确,请检查数据库编号");
|
||||
throw new RuntimeException("redis数据库编号:" + redisDBIndex + "不正确,请检查数据库编号");
|
||||
}
|
||||
}
|
||||
if (count == configMap.size()) {
|
||||
@@ -513,11 +512,14 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
transaction.exec();
|
||||
}
|
||||
} catch (JedisConnectionException e) {
|
||||
// transaction.discard();
|
||||
throw new RuntimeException("后台错误:连接redis异常,保存maat类配置失败", e);
|
||||
String error = "后台错误:连接redis异常,保存maat类配置失败" + e.getMessage();
|
||||
logger.error(error);
|
||||
throw new RuntimeException(error, e);
|
||||
} catch (Exception e) {
|
||||
transaction.discard();
|
||||
throw new RuntimeException("后台错误:保存maat类配置发生了异常", e);
|
||||
String error = "后台错误:保存maat类配置发生了异常" + e.getMessage();
|
||||
logger.error(error);
|
||||
throw new RuntimeException(error, e);
|
||||
} finally {
|
||||
// 释放连接到连接池
|
||||
JedisUtils.returnResource(resource);
|
||||
@@ -546,8 +548,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
setCommonConfig(maatXmlConfig, compileMap, 10, maatVersion.doubleValue(), service, transaction,
|
||||
redisDBIndex, null);// 10代表是编译配置
|
||||
} else {
|
||||
throw new RuntimeException(
|
||||
"后台错误:无法从参数中获取" + redisDBIndex + "号redis库,业务类型为:" + service + "的编译配置信息,请检查配置参数是否正确");
|
||||
throw new RuntimeException("无法从参数中获取" + redisDBIndex + "号redis库,业务类型为:" + service + "的编译配置信息,请检查配置参数是否正确");
|
||||
}
|
||||
|
||||
List<Map<String, String>> groupMapList = maatConfig.getGroupMapList();
|
||||
@@ -557,8 +558,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
compileId);// 11代表是分组配置
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException(
|
||||
"后台错误:无法从参数中获取" + redisDBIndex + "号redis库,业务类型为:" + service + "的分组配置信息,请检查配置参数是否正确");
|
||||
throw new RuntimeException("无法从参数中获取" + redisDBIndex + "号redis库,业务类型为:" + service + "的分组配置信息,请检查配置参数是否正确");
|
||||
}
|
||||
|
||||
List<Map<String, String>> ipRegionMapList = maatConfig.getIpRegionMapList();
|
||||
@@ -641,7 +641,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
if (keyVal != null && !keyVal.equals("")) {
|
||||
keyBF.append(keyVal);
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:未从map中获取到" + keyStr + "的值,无法拼接redisKey,请检查数据是否正确");
|
||||
throw new RuntimeException("未从map中获取到" + keyStr + "的值,无法拼接redisKey,请检查数据是否正确");
|
||||
}
|
||||
if (type == 11 && keyStr.toLowerCase().equals("group_id")) {
|
||||
keyBF.append(compileId);
|
||||
@@ -654,7 +654,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
argTableName == null ? null : argTableName);
|
||||
if (maatTableName == null) {
|
||||
throw new RuntimeException(
|
||||
"后台错误:未从业务类型和表对应关系中,找到业务类型:" + service + ",配置类型:" + type + ",对应的真实表名");
|
||||
"未从业务类型和表对应关系中,找到业务类型:" + service + ",配置类型:" + type + ",对应的真实表名");
|
||||
} else {
|
||||
keyBF.append(maatTableName);
|
||||
}
|
||||
@@ -703,7 +703,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
valBF.append(val);
|
||||
} else {
|
||||
// 所有在maat.xml中配置的属性都不可以为空
|
||||
throw new RuntimeException("后台错误:未从map中获取到" + valStr + "的值,无法拼接redisValue,请检查数据是否正确");
|
||||
throw new RuntimeException("未从map中获取到" + valStr + "的值,无法拼接redisValue,请检查数据是否正确");
|
||||
}
|
||||
} else if (valStr.equals(" ")) {
|
||||
valBF.append(" ");
|
||||
@@ -748,9 +748,9 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
}
|
||||
} else {
|
||||
if (maatXmlConfig == null) {
|
||||
throw new RuntimeException("后台错误:无法获取业务类型" + service + "对应的maat规则,请检查maat.xml");
|
||||
throw new RuntimeException("无法获取业务类型" + service + "对应的maat规则,请检查maat.xml");
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:后台组装的配置信息有误,请联系管理员检查");
|
||||
throw new RuntimeException("后台组装的配置信息有误,请联系管理员检查");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -775,7 +775,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
|
||||
String maatVersionStr = JedisUtils.get("MAAT_VERSION", redisDBIndex);
|
||||
if (maatVersionStr == null) {
|
||||
throw new RuntimeException("后台错误:从" + redisDBIndex
|
||||
throw new RuntimeException("从" + redisDBIndex
|
||||
+ "号redis库中获取MAAT_VERSION的值为null,redis中不存在该值,请联系开发人员检查删除逻辑是否正确或redis数据是否出现了异常");
|
||||
}
|
||||
if (maatVersionStr != null) {
|
||||
@@ -815,8 +815,8 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
.getUnMaatTableName(service);
|
||||
if (maatTableName == null) {
|
||||
throw new RuntimeException(
|
||||
"后台错误:未从业务类型和表对应关系中,找到非maat配置业务类型:"
|
||||
+ service + "对应的真实表名");
|
||||
"未从业务类型和表对应关系中,找到非maat配置业务类型:" + service
|
||||
+ "对应的真实表名");
|
||||
} else {
|
||||
keyBF.append(maatTableName);
|
||||
}
|
||||
@@ -842,8 +842,8 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
maatKey.toString().toUpperCase());
|
||||
break;
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:" + redisDBIndex
|
||||
+ "号redis库中不存在key=" + oldKey + "请检查id映射关系是否正确");
|
||||
throw new RuntimeException(redisDBIndex + "号redis库中不存在key="
|
||||
+ oldKey + "请检查id映射关系是否正确");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -899,7 +899,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException(
|
||||
"后台错误:无法从maat.xml中获取业务类型" + service + "对应的规则,请检查业务类型是否正确");
|
||||
"无法从maat.xml中获取业务类型" + service + "对应的规则,请检查业务类型是否正确");
|
||||
}
|
||||
}
|
||||
transaction.incrBy("MAAT_VERSION", 1l);
|
||||
@@ -908,14 +908,14 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
Integer.valueOf(maatVersionStr) + 1);
|
||||
count++;
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:无法从参数中获取" + redisDBIndex + "号redis库,业务类型为:"
|
||||
+ service + "的配置id信息,请检查配置参数是否正确");
|
||||
throw new RuntimeException("无法从参数中获取" + redisDBIndex + "号redis库,业务类型为:" + service
|
||||
+ "的配置id信息,请检查配置参数是否正确");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:向" + redisDBIndex + "号redis库中添加配置时,未发现对应的配置信息,请检查配置参数是否正确");
|
||||
throw new RuntimeException("向" + redisDBIndex + "号redis库中添加配置时,未发现对应的配置信息,请检查配置参数是否正确");
|
||||
}
|
||||
|
||||
}
|
||||
@@ -926,11 +926,14 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
transaction.discard();
|
||||
}
|
||||
} catch (JedisConnectionException e) {
|
||||
// transaction.discard();
|
||||
throw new RuntimeException("后台错误:连接redis异常,删除非maat类配置失败", e);
|
||||
String error = "后台错误:连接redis异常,删除非maat类配置失败," + e.getMessage();
|
||||
logger.error(error);
|
||||
throw new RuntimeException(error, e);
|
||||
} catch (Exception e) {
|
||||
transaction.discard();
|
||||
throw new RuntimeException("后台错误:删除非maat类配置发生了异常", e);
|
||||
String error = "后台错误:删除非maat类配置发生了异常," + e.getMessage();
|
||||
logger.error(error);
|
||||
throw new RuntimeException(error, e);
|
||||
} finally {
|
||||
// 释放连接到连接池
|
||||
JedisUtils.returnResource(resource);
|
||||
@@ -955,7 +958,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
if (serviceConfigMap != null && serviceConfigMap.size() > 0) {
|
||||
String maatVersionStr = JedisUtils.get("MAAT_VERSION", redisDBIndex);
|
||||
if (maatVersionStr == null) {
|
||||
throw new RuntimeException("后台错误:从" + redisDBIndex
|
||||
throw new RuntimeException("从" + redisDBIndex
|
||||
+ "号redis库中获取MAAT_VERSION的值为null,redis中不存在该值,请联系开发人员检查删除逻辑是否正确或redis数据是否出现了异常");
|
||||
}
|
||||
if (maatVersionStr != null) {
|
||||
@@ -972,7 +975,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
count++;
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:向" + redisDBIndex + "号redis库中添加配置时,未发现对应的配置信息,请检查配置参数是否正确");
|
||||
throw new RuntimeException("向" + redisDBIndex + "号redis库中添加配置时,未发现对应的配置信息,请检查配置参数是否正确");
|
||||
}
|
||||
}
|
||||
if (count == idMap.size()) {
|
||||
@@ -985,11 +988,14 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
}
|
||||
|
||||
} catch (JedisConnectionException e) {
|
||||
// transaction.discard();
|
||||
throw new RuntimeException("后台错误:连接redis异常,删除maat类配置失败", e);
|
||||
String error = "后台错误:连接redis异常,删除maat类配置失败," + e.getMessage();
|
||||
logger.error(error);
|
||||
throw new RuntimeException(error, e);
|
||||
} catch (Exception e) {
|
||||
transaction.discard();
|
||||
throw new RuntimeException("后台错误:删除maat类配置发生了异常", e);
|
||||
String error = "后台错误:删除maat类配置发生了异常," + e.getMessage();
|
||||
logger.error(error);
|
||||
throw new RuntimeException(error, e);
|
||||
} finally {
|
||||
// 释放连接到连接池
|
||||
JedisUtils.returnResource(resource);
|
||||
@@ -1038,7 +1044,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException(
|
||||
"后台错误:从" + idRelaRedisDBIndex + "号redis库中获取" + groupRegionKey
|
||||
"从" + idRelaRedisDBIndex + "号redis库中获取" + groupRegionKey
|
||||
+ "的值为null,redis中不存在该值,请联系开发人员检查删除逻辑是否正确或redis数据是否出现了异常");
|
||||
|
||||
}
|
||||
@@ -1049,18 +1055,18 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
groupId.replace(redisDBIndex + ":GROUPCOMPILE:", ""), 11, maatVersion.doubleValue(),
|
||||
service, transaction, redisDBIndex, id + "");// 11代表是分组配置
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:从" + idRelaRedisDBIndex + "号redis库中获取" + groupId
|
||||
throw new RuntimeException("从" + idRelaRedisDBIndex + "号redis库中获取" + groupId
|
||||
+ "的值为null,redis中不存在该值,请联系开发人员检查删除逻辑是否正确或redis数据是否出现了异常");
|
||||
|
||||
}
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:从" + idRelaRedisDBIndex + "号redis库中获取" + compileStr
|
||||
throw new RuntimeException("从" + idRelaRedisDBIndex + "号redis库中获取" + compileStr
|
||||
+ "的值为null,redis中不存在该值,请联系开发人员检查删除逻辑是否正确或redis数据是否出现了异常");
|
||||
}
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:无法获取内存中记录的id映射关系,无法获取业务类型" + service + "对应的maat规则或传入的配置id有误,请检查!");
|
||||
throw new RuntimeException("无法获取内存中记录的id映射关系,无法获取业务类型" + service + "对应的maat规则或传入的配置id有误,请检查!");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1092,7 +1098,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
String maatTableName = ServiceAndRDBIndexReal.getMaatTableName(service, type, null);
|
||||
if (maatTableName == null) {
|
||||
throw new RuntimeException(
|
||||
"后台错误:未从业务类型和表对应关系中,找到业务类型:" + service + ",配置类型:" + type + ",对应的真实表名");
|
||||
"未从业务类型和表对应关系中,找到业务类型:" + service + ",配置类型:" + type + ",对应的真实表名");
|
||||
} else {
|
||||
keyBF.append(maatTableName);
|
||||
}
|
||||
@@ -1113,7 +1119,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
maatKey.toUpperCase());
|
||||
break;
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:" + redisDBIndex + "号redis库中不存在key=" + oldKey
|
||||
throw new RuntimeException(redisDBIndex + "号redis库中不存在key=" + oldKey
|
||||
+ "请检查id映射关系是否正确,或该配置已经被取消,已经被取消的配置不可再次取消,否则将抛出异常");
|
||||
}
|
||||
}
|
||||
@@ -1147,7 +1153,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
}
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:无法获取业务类型" + service + "对应的maat规则,请检查!");
|
||||
throw new RuntimeException("无法获取业务类型" + service + "对应的maat规则,请检查!");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1172,7 +1178,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
transaction.rename(oldKey, maatKey.toUpperCase());
|
||||
logger.info("向{}号redis数据库修改了一条配置,修改前key是{},修改后key是{}", redisDBIndex, oldKey, maatKey.toUpperCase());
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:" + redisDBIndex + "号redis库中不存在key=" + oldKey + "请检查id映射关系是否正确");
|
||||
throw new RuntimeException(redisDBIndex + "号redis库中不存在key=" + oldKey + "请检查id映射关系是否正确");
|
||||
}
|
||||
|
||||
for (MaatXmlExpr maatXmlExpr : expressionList) {
|
||||
@@ -1205,10 +1211,10 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
}
|
||||
} else {
|
||||
if (maatXmlConfig == null) {
|
||||
throw new RuntimeException("后台错误:无法获取业务类型" + service + "对应的maat规则,请检查maat.xml");
|
||||
throw new RuntimeException("无法获取业务类型" + service + "对应的maat规则,请检查maat.xml");
|
||||
} else {
|
||||
int idRelaRedisDBIndex = Configurations.getIntProperty("idRelaRedisDBIndex", 15);
|
||||
throw new RuntimeException("后台错误:" + idRelaRedisDBIndex + "号redis库中存储的分组和域关系有误,请联系管理员检查数据");
|
||||
throw new RuntimeException(idRelaRedisDBIndex + "号redis库中存储的分组和域关系有误,请联系管理员检查数据");
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1223,7 +1229,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
transaction.select(redisStatisticsRealDBIndex);
|
||||
String maatVersionStr = JedisUtils.get("MAAT_VERSION", redisStatisticsRealDBIndex);
|
||||
if (maatVersionStr == null) {
|
||||
throw new RuntimeException("后台错误:从" + redisStatisticsRealDBIndex
|
||||
throw new RuntimeException("从" + redisStatisticsRealDBIndex
|
||||
+ "号redis库中获取MAAT_VERSION的值为null,redis中不存在该值,请联系开发人员检查删除逻辑是否正确或redis数据是否出现了异常");
|
||||
}
|
||||
double maatVersion = Double.valueOf(maatVersionStr) + 1D;
|
||||
@@ -1251,7 +1257,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
logger.info("向{}号redis数据库更新了MAAT_UPDATE_STATUS,内容是{},SCORES是{}",
|
||||
redisStatisticsRealDBIndex, zset.toUpperCase(), maatVersion);
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:从" + redisStatisticsRealDBIndex + "号redis库中判断"
|
||||
throw new RuntimeException("从" + redisStatisticsRealDBIndex + "号redis库中判断"
|
||||
+ effectiveRuleKey.toUpperCase()
|
||||
+ "组和域关系时不存在,请联系开发人员检查删除逻辑是否正确或redis数据是否出现了异常");
|
||||
|
||||
@@ -1259,7 +1265,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:删除配置时,配置id不能为空,请联系开发人员检查删除逻辑是否正确");
|
||||
throw new RuntimeException("删除配置时,配置id不能为空,请联系开发人员检查删除逻辑是否正确");
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1268,11 +1274,11 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
Integer.valueOf(maatVersionStr) + 1);
|
||||
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:删除配置时,配置id不能为空,请联系开发人员检查删除逻辑是否正确");
|
||||
throw new RuntimeException("删除配置时,配置id不能为空,请联系开发人员检查删除逻辑是否正确");
|
||||
}
|
||||
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:redis数据库编号:" + redisStatisticsRealDBIndex + "不正确,请检查数据库编号");
|
||||
throw new RuntimeException("redis数据库编号:" + redisStatisticsRealDBIndex + "不正确,请检查数据库编号");
|
||||
}
|
||||
break;// 因为所有的value都是相同的所以只取消一次就可以了
|
||||
}
|
||||
@@ -1319,7 +1325,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
if (JedisUtils.exists(groupRegion, idRelaRedisDBIndex)) {
|
||||
transaction.del(groupRegion);// 删除组对应的域
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:从" + idRelaRedisDBIndex
|
||||
throw new RuntimeException("从" + idRelaRedisDBIndex
|
||||
+ "号redis库中判断" + groupRegion
|
||||
+ "组和域关系时不存在,请联系开发人员检查删除逻辑是否正确或redis数据是否出现了异常");
|
||||
|
||||
@@ -1329,7 +1335,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
idRelaRedisDBIndex)) {
|
||||
transaction.del(groupCompile.toUpperCase());// 删除当前组所对应的编译
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:从" + idRelaRedisDBIndex
|
||||
throw new RuntimeException("从" + idRelaRedisDBIndex
|
||||
+ "号redis库中判断" + groupCompile.toUpperCase()
|
||||
+ "组和域关系时不存在,请联系开发人员检查删除逻辑是否正确或redis数据是否出现了异常");
|
||||
|
||||
@@ -1352,7 +1358,7 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
transaction.set(groupCompile, sb.substring(0, sb.length() - 1));
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:从" + idRelaRedisDBIndex + "号redis库中获取"
|
||||
throw new RuntimeException("从" + idRelaRedisDBIndex + "号redis库中获取"
|
||||
+ groupCompile.toUpperCase()
|
||||
+ "的值为null,redis中不存在该值,请联系开发人员检查删除逻辑是否正确或redis数据是否出现了异常");
|
||||
|
||||
@@ -1363,8 +1369,8 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
}
|
||||
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:从" + idRelaRedisDBIndex + "号redis库中获取"
|
||||
+ compileStr + "的值为null,redis中不存在该值,请联系开发人员检查删除逻辑是否正确或redis数据是否出现了异常");
|
||||
throw new RuntimeException("从" + idRelaRedisDBIndex + "号redis库中获取" + compileStr
|
||||
+ "的值为null,redis中不存在该值,请联系开发人员检查删除逻辑是否正确或redis数据是否出现了异常");
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1372,11 +1378,11 @@ public class ConfigJedisServiceimpl implements ConfigRedisService {
|
||||
}
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:redis数据库编号:" + redisDBIndex + "不正确,请检查数据库编号");
|
||||
throw new RuntimeException("redis数据库编号:" + redisDBIndex + "不正确,请检查数据库编号");
|
||||
}
|
||||
}
|
||||
} else {
|
||||
throw new RuntimeException("后台错误:参数不能为空");
|
||||
throw new RuntimeException("参数不能为空");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user