diff --git a/jsowell-quartz/src/main/java/com/jsowell/quartz/task/JsowellTask.java b/jsowell-quartz/src/main/java/com/jsowell/quartz/task/JsowellTask.java index 6ade0862d..915c9bf7a 100644 --- a/jsowell-quartz/src/main/java/com/jsowell/quartz/task/JsowellTask.java +++ b/jsowell-quartz/src/main/java/com/jsowell/quartz/task/JsowellTask.java @@ -257,10 +257,14 @@ public class JsowellTask { .collect(Collectors.toList()); for (String stationId : stationIdList) { - NotificationDTO dto = new NotificationDTO(); - dto.setStationId(stationId); - dto.setPlatformType(thirdPartyType); - notificationService.notificationStationPowerInfo(dto); + try { + NotificationDTO dto = new NotificationDTO(); + dto.setStationId(stationId); + dto.setPlatformType(thirdPartyType); + notificationService.notificationStationPowerInfo(dto); + } catch (Exception e) { + log.error("平台类型:{},站点ID:{},推送充电站实时功率失败", thirdPartyType, stationId, e); + } } } @@ -339,10 +343,14 @@ public class JsowellTask { .collect(Collectors.toList()); for (String stationId : stationIdList) { - NotificationDTO dto = new NotificationDTO(); - dto.setStationId(stationId); - dto.setPlatformType(thirdPartyType); - notificationService.notificationOperationStatsInfo(dto); + try { + NotificationDTO dto = new NotificationDTO(); + dto.setStationId(stationId); + dto.setPlatformType(thirdPartyType); + notificationService.notificationOperationStatsInfo(dto); + } catch (Exception e) { + log.error("平台类型:{},站点ID:{},推送统计信息失败", thirdPartyType, stationId, e); + } } }