2021与蓝度共同重构项目,服务端
Van333
2022-12-05 694d691291f6ee89061fdbb9fd451ecb5519b69b
ximon-admin/src/main/java/com/sandu/ximon/admin/service/PoleService.java
@@ -60,6 +60,7 @@
import java.util.concurrent.atomic.AtomicInteger;
import java.util.stream.Collectors;
/**
 * 灯杆相关
 *
@@ -1050,7 +1051,7 @@
     * @return 设备状态列表
     */
    public List<DeviceStatus> listStatusByDeviceCode(ArrayList<String> deviceCodeList) {
        // 最大只能查50个
//         最大只能查50个
        List<List<String>> split = CollectionUtil.split(deviceCodeList, 50);
        List<DeviceStatus> statusList = new ArrayList<>();
        for (List<String> list : split) {
@@ -1064,6 +1065,8 @@
                }
            }
        }
        return statusList;
    }
@@ -1338,7 +1341,7 @@
        //设置触发条件    存入Redis  15分钟超时   15分钟内再次调用直接返回
        redisUtils.set("redisStatusKeyTimeout", System.currentTimeMillis(), 60 * 15);
        CountDownLatch countDownLatch = new CountDownLatch(7);//todo
        CountDownLatch countDownLatch = new CountDownLatch(7);//todo 几个设备设置为几
        //获取一个7位随机数
        String str = RandomStringUtils.randomAlphanumeric(7);
        countDownLatchUtil.push(str, countDownLatch);
@@ -1419,4 +1422,4 @@
    }
}
}