全民福利,单个服务器生效

back_recharge
duhui 2022-09-19 14:48:50 +08:00
parent 56e993f2a9
commit d9c771e49b
2 changed files with 3 additions and 8 deletions

View File

@ -1485,12 +1485,7 @@ public class RedisUtil {
return type + RedisKey.Delimiter_colon + key;
}
if (result == null) {
// if (RedisKey.GUILD_RELEASE.equals(type)) {
// RedisUtil.getInstence().get(RedisKey.GUILD_SERVERID + RedisKey.Delimiter_colon + )
// result = + RedisKey.Delimiter_colon + type + RedisKey.Delimiter_colon + key;
// }else {
result = AreaManager.areaId + RedisKey.Delimiter_colon + type + RedisKey.Delimiter_colon + key;
// }
result = AreaManager.areaId + RedisKey.Delimiter_colon + type + RedisKey.Delimiter_colon + key;
}
// 保存需要清理的key
saveRemoveKeyHandler(result);

View File

@ -59,13 +59,13 @@ public class AllPeopleWelfareActivity extends AbstractActivity {
}
public static int getValue(int goodId){
Integer value = RedisUtil.getInstence().getMapValue(RedisKey.ALL_PEOPLE_WELFARE_BUY_COUNT, String.valueOf(goodId), Integer.class);
Integer value = RedisUtil.getInstence().getMapValue(RedisKey.ALL_PEOPLE_WELFARE_BUY_COUNT,"", String.valueOf(goodId), Integer.class);
return Optional.ofNullable(value).orElse(0);
}
public static void addValue(int goodId, int count){
int value = getValue(goodId)+count;
RedisUtil.getInstence().putMapEntry(RedisKey.ALL_PEOPLE_WELFARE_BUY_COUNT, String.valueOf(goodId), value);
RedisUtil.getInstence().putMapEntry(RedisKey.ALL_PEOPLE_WELFARE_BUY_COUNT,"", String.valueOf(goodId), value);
}
/**