diff --git a/zc-business/src/main/java/com/zc/business/controller/SideSlopeController.java b/zc-business/src/main/java/com/zc/business/controller/SideSlopeController.java index 367a4cb2..f3710aba 100644 --- a/zc-business/src/main/java/com/zc/business/controller/SideSlopeController.java +++ b/zc-business/src/main/java/com/zc/business/controller/SideSlopeController.java @@ -319,8 +319,14 @@ public class SideSlopeController extends BaseController { logger.info("边坡监测mqtt开始监听" + topicName); } catch (MqttException e) { - logger.warn("边坡监测mqtt连接异常"); - mqttSubscription(); + logger.warn("边坡监测mqtt连接异常",e); + scheduler.schedule(() -> { + try { + mqttSubscription(); + } catch (Exception exception) { + throw new RuntimeException(exception); + } + }, UniversalEnum.TEN.getNumber(), TimeUnit.SECONDS); } } catch (Exception e) { e.printStackTrace();