From b96648b1559bd3b2c2fdb73a58f875403760c555 Mon Sep 17 00:00:00 2001 From: Alex Holliday Date: Fri, 22 Nov 2024 11:55:31 +0800 Subject: [PATCH] add hardware monitor notification checking to jobQueue --- Server/service/jobQueue.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Server/service/jobQueue.js b/Server/service/jobQueue.js index eedeb1a5c..dd3ac010a 100644 --- a/Server/service/jobQueue.js +++ b/Server/service/jobQueue.js @@ -166,6 +166,15 @@ class JobQueue { const { monitor, statusChanged, prevStatus } = await this.statusService.updateStatus(networkResponse); + // If this is an infrastructure monitor, we need to check for thresholds + if (monitor.type === "hardware") { + await this.notificationService.handleInfrastructureNotifications({ + ...networkResponse, + monitor, + prevStatus, + }); + } + //If status hasn't changed, we're done if (statusChanged === false) return;