| | |
| | | |
| | | @Override |
| | | public List<ShuttleProtocol> getShuttleStatusList(Long hostId) { |
| | | |
| | | ArrayList<ShuttleProtocol> data = new ArrayList<>(); |
| | | List<Device> list = deviceService.list(new LambdaQueryWrapper<Device>() |
| | | .eq(Device::getHostId, hostId) |
| | |
| | | .eq(Device::getDeviceType, DeviceCtgType.SHUTTLE.val())); |
| | | for (Device device : list) { |
| | | ShuttleThread shuttleThread = (ShuttleThread) SlaveConnection.get(SlaveType.Shuttle, device.getId().intValue()); |
| | | if (shuttleThread == null) { |
| | | continue; |
| | | } |
| | | ShuttleProtocol status = shuttleThread.getStatus(); |
| | | data.add(status); |
| | | } |