sqlinsight-pro/tests/SQLInsight.Servers.Tests
Søren Eggert Lundsteen Olsen 6eae719e95 Agent: monitor Windows servers and run synthetic checks; server tests and check runs on request
- ServerMonitoringService keeps the SQL Server hosts in step with the monitored
  instances (SQLInsight:Servers:IncludeSqlHosts), picks up servers added, paused or
  changed in SQLInsight Web within a minute, and runs each server's due areas with
  a limit on parallelism. Default intervals: 1 min CPU/memory, 15 min disks and
  tasks, 5 min services and events (SQLInsight:Servers:Intervals).
- ServerMonitor: one CIM session per cycle; per-minute samples, disk samples and
  the "fuld om ca. N dage" forecast from the stored history, grouped events (read
  from where the last read stopped), services and tasks. A missing right makes
  only that area "ikke målbar" with the exact reason, logged once per change; a
  server that does not answer is notified once, and again when it answers.
  Survives an agent restart (samples, boot time, event position).
- SyntheticCheckService runs checks on their interval, opens a SQL login password
  sealed for the agent (AgentCredentialKey.OpenContext), looks up the linked
  Windows service when a check fails, stores results and findings, notifies with
  links to /servere/fund/{id}.
- AgentRequestService hands ServerTest and SyntheticCheckRun to ServerRequestHandler.
- appsettings.json: SQLInsight:Servers and SQLInsight:SyntheticChecks with every
  threshold, interval and retention.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-02 14:58:36 +02:00
..
LocalCimTests.cs Agent: monitor Windows servers and run synthetic checks; server tests and check runs on request 2026-10-02 14:58:36 +02:00
ServerAccessTests.cs Collection: Windows servers over CIM (WS-Man, DCOM fallback) and synthetic check runners 2026-10-02 14:58:18 +02:00
SQLInsight.Servers.Tests.csproj Collection: Windows servers over CIM (WS-Man, DCOM fallback) and synthetic check runners 2026-10-02 14:58:18 +02:00
SyntheticCheckRunnerTests.cs Collection: Windows servers over CIM (WS-Man, DCOM fallback) and synthetic check runners 2026-10-02 14:58:18 +02:00