From ca253b190f448e79628dd91459a0e674c37bfb4a Mon Sep 17 00:00:00 2001 From: Oliver Kieselbach Date: Tue, 17 Mar 2026 16:08:40 +0100 Subject: [PATCH] removed backend url check, only a few critical urls to verify connectivity --- .../Monitoring/Collectors/NetworkChangeDetector.cs | 11 +++++++---- src/Agent/AutopilotMonitor.Agent/buildcounter.txt | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/src/Agent/AutopilotMonitor.Agent.Core/Monitoring/Collectors/NetworkChangeDetector.cs b/src/Agent/AutopilotMonitor.Agent.Core/Monitoring/Collectors/NetworkChangeDetector.cs index 4585b575..224f2837 100644 --- a/src/Agent/AutopilotMonitor.Agent.Core/Monitoring/Collectors/NetworkChangeDetector.cs +++ b/src/Agent/AutopilotMonitor.Agent.Core/Monitoring/Collectors/NetworkChangeDetector.cs @@ -226,10 +226,13 @@ namespace AutopilotMonitor.Agent.Core.Monitoring.Collectors // Build endpoint list: static MDM endpoints + dynamic backend URL var endpoints = new List<(string Name, string Url)>(MdmEndpoints); - if (!string.IsNullOrEmpty(_apiBaseUrl)) - { - endpoints.Add(("Autopilot Monitor API", _apiBaseUrl)); - } + // Optionally add the Autopilot Monitor API endpoint, but we don't want to cause false alarms if it's down or unreachable, + // since it's not critical for enrollment success and may be available only after certain network changes (e.g. if it's behind a captive portal). + // For now, we can omit it from the critical checks. + // if (!string.IsNullOrEmpty(_apiBaseUrl)) + // { + // endpoints.Add(("Autopilot Monitor API", _apiBaseUrl)); + // } // Run all checks in parallel var tasks = endpoints.Select(ep => CheckEndpointAsync(ep.Name, ep.Url)).ToArray(); diff --git a/src/Agent/AutopilotMonitor.Agent/buildcounter.txt b/src/Agent/AutopilotMonitor.Agent/buildcounter.txt index 534b992c..515f19a5 100644 --- a/src/Agent/AutopilotMonitor.Agent/buildcounter.txt +++ b/src/Agent/AutopilotMonitor.Agent/buildcounter.txt @@ -1 +1 @@ -453 +454