2026/4/6 9:36:38
网站建设
项目流程
百度网站禁止访问怎么解除,wordpress有中文版吗,企业网站建设知名,wordpress文章字体大小插件文章目录问题解决问题
在应用启动的时候#xff0c;程序出现异常。存储类的部分字段如下#xff1a; 每分钟进行检测#xff1a; 出现了#xff1a;
解决
ConcurrentHashMap 是线程安全#xff0c;这个问题#xff0c;是因为 SiegeWarRoomCache 通过 FastJson 存储在…文章目录问题解决问题在应用启动的时候程序出现异常。存储类的部分字段如下每分钟进行检测出现了解决ConcurrentHashMap 是线程安全这个问题是因为 SiegeWarRoomCache 通过 FastJson 存储在 redis中在启动的时候加载。虽然字段做了privateSetLongroomActorsnewConcurrentHashSet();的处理但是在 FastJson 发序列化的时候该字段的值被覆盖publicSetLonggetRoomActors(){returnroomActors;}publicvoidsetRoomActors(SetLongroomActors){this.roomActorsroomActors;}正确的应该是publicSetLonggetRoomActors(){returnroomActors;}publicvoidsetRoomActors(SetLongroomActors){this.roomActors.clear();this.roomActors.addAll(roomActors);}