docs(health): CentralHealthReportLoop comments say oldest-member, not cluster leader — stop re-teaching the S2 conflation (plan R2-01 T9)
This commit is contained in:
@@ -9,9 +9,11 @@ namespace ZB.MOM.WW.ScadaBridge.HealthMonitoring;
|
|||||||
/// Periodically builds a SiteHealthReport for the central cluster itself
|
/// Periodically builds a SiteHealthReport for the central cluster itself
|
||||||
/// (siteId = <see cref="CentralSiteId"/>) and feeds it into the local
|
/// (siteId = <see cref="CentralSiteId"/>) and feeds it into the local
|
||||||
/// CentralHealthAggregator so the UI can render central as another card
|
/// CentralHealthAggregator so the UI can render central as another card
|
||||||
/// on /monitoring/health. Only the cluster leader (Primary) generates
|
/// on /monitoring/health. Only the active node (Primary = the **oldest Up
|
||||||
/// reports — the standby's aggregator catches up on failover when it
|
/// member**, i.e. the singleton host — <c>IClusterNodeProvider.SelfIsPrimary</c>,
|
||||||
/// becomes Primary and starts its own loop.
|
/// never Akka cluster leadership) generates reports; the standby's aggregator
|
||||||
|
/// catches up on failover when it becomes the oldest and its loop starts
|
||||||
|
/// reporting.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public class CentralHealthReportLoop : BackgroundService
|
public class CentralHealthReportLoop : BackgroundService
|
||||||
{
|
{
|
||||||
@@ -41,8 +43,9 @@ public class CentralHealthReportLoop : BackgroundService
|
|||||||
private readonly HealthMonitoringOptions _options;
|
private readonly HealthMonitoringOptions _options;
|
||||||
private readonly ILogger<CentralHealthReportLoop> _logger;
|
private readonly ILogger<CentralHealthReportLoop> _logger;
|
||||||
|
|
||||||
// Seeded with Unix-ms so reports from a newly-elected central leader
|
// Seeded with Unix-ms so reports from a node that has newly become active
|
||||||
// always sort after reports from any prior leader for siteId="central".
|
// (oldest Up member) always sort after reports from any previously-active
|
||||||
|
// node for siteId="central".
|
||||||
// The clock is read through the injected TimeProvider so the seeding is
|
// The clock is read through the injected TimeProvider so the seeding is
|
||||||
// deterministically testable.
|
// deterministically testable.
|
||||||
private long _sequenceNumber;
|
private long _sequenceNumber;
|
||||||
|
|||||||
Reference in New Issue
Block a user