- 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>
32 lines
1.9 KiB
XML
32 lines
1.9 KiB
XML
<Project Sdk="Microsoft.NET.Sdk.Worker">
|
|
<PropertyGroup>
|
|
<RootNamespace>SQLInsight.Agent</RootNamespace>
|
|
<UserSecretsId>sqlinsight-agent</UserSecretsId>
|
|
</PropertyGroup>
|
|
<ItemGroup>
|
|
<ProjectReference Include="..\SQLInsight.Core\SQLInsight.Core.csproj" />
|
|
<ProjectReference Include="..\SQLInsight.Connectivity\SQLInsight.Connectivity.csproj" />
|
|
<ProjectReference Include="..\SQLInsight.Rules\SQLInsight.Rules.csproj" />
|
|
<ProjectReference Include="..\SQLInsight.Collectors\SQLInsight.Collectors.csproj" />
|
|
<ProjectReference Include="..\SQLInsight.Repository\SQLInsight.Repository.csproj" />
|
|
<ProjectReference Include="..\SQLInsight.Notifications\SQLInsight.Notifications.csproj" />
|
|
<ProjectReference Include="..\SQLInsight.Contracts\SQLInsight.Contracts.csproj" />
|
|
<ProjectReference Include="..\SQLInsight.Licensing\SQLInsight.Licensing.csproj" />
|
|
<ProjectReference Include="..\SQLInsight.Updates\SQLInsight.Updates.csproj" />
|
|
<ProjectReference Include="..\SQLInsight.Reports\SQLInsight.Reports.csproj" />
|
|
<ProjectReference Include="..\SQLInsight.Servers\SQLInsight.Servers.csproj" />
|
|
</ItemGroup>
|
|
<ItemGroup>
|
|
<PackageReference Include="Microsoft.Extensions.Hosting" />
|
|
<PackageReference Include="Microsoft.Extensions.Http" />
|
|
<PackageReference Include="Microsoft.Extensions.Hosting.WindowsServices" />
|
|
<PackageReference Include="Microsoft.Extensions.Configuration.Ini" />
|
|
<PackageReference Include="Microsoft.Extensions.Hosting.Systemd" />
|
|
<PackageReference Include="System.DirectoryServices.AccountManagement" />
|
|
<PackageReference Include="System.Security.Cryptography.ProtectedData" />
|
|
</ItemGroup>
|
|
<ItemGroup>
|
|
<!-- setup-repository gives the agent these rights on the monitored instances (Setup/RepositorySetup.cs). -->
|
|
<EmbeddedResource Include="..\..\db\permissions\grant-least-privilege.sql" LogicalName="grant-least-privilege.sql" />
|
|
</ItemGroup>
|
|
</Project>
|