Commit b1fc6a02 by 罗志长

fix: 时间差

parent 3615fb07
......@@ -882,10 +882,10 @@ public class PlatDeviceServiceImpl extends ServiceImpl<PlatDeviceMapper, PlatDev
platRoomBedDeviceService.remove(new QueryWrapper<PlatRoomBedDevice>().lambda()
.in(PlatRoomBedDevice::getDeviceId,deviceIdList)
.eq(BaseBusEntity::getTenantId, platTenant.getId()));
// 10s后删除缓存里的设备
// 2分钟后删除缓存里的设备
newPlatformDeviceIdSet.forEach(deviceId -> {
String key = RedisConst.PLAT_OWN_IOT_DEVICE_ID + deviceId;
RedisUtil.expire(key, 10, TimeUnit.SECONDS);
RedisUtil.expire(key, 2, TimeUnit.MINUTES);
});
}
if (CollectionUtils.isEmpty(iotDeviceIdSet)) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment