feat(host): add NodeName to NodeOptions + INodeIdentityProvider
- NodeName: semantic role-within-cluster identifier (node-a/node-b on sites, central-a/central-b on central). Bound from ScadaLink:Node:NodeName. - INodeIdentityProvider exposes the trimmed name (null if unconfigured) so downstream audit writers can stamp the new SourceNode column.
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
using ScadaLink.AuditLog;
|
||||
using ScadaLink.ClusterInfrastructure;
|
||||
using ScadaLink.Communication;
|
||||
using ScadaLink.Commons.Interfaces.Services;
|
||||
using ScadaLink.DataConnectionLayer;
|
||||
using ScadaLink.ExternalSystemGateway;
|
||||
using ScadaLink.HealthMonitoring;
|
||||
@@ -96,5 +97,10 @@ public static class SiteServiceRegistration
|
||||
services.Configure<HealthMonitoringOptions>(config.GetSection("ScadaLink:HealthMonitoring"));
|
||||
services.Configure<NotificationOptions>(config.GetSection("ScadaLink:Notification"));
|
||||
services.Configure<LoggingOptions>(config.GetSection("ScadaLink:Logging"));
|
||||
|
||||
// Audit Log (#23) — exposes ScadaLink:Node:NodeName to downstream audit
|
||||
// writers so they can stamp the SourceNode column. Registered here in
|
||||
// shared bootstrap because every node (central + site) needs it.
|
||||
services.AddSingleton<INodeIdentityProvider, NodeIdentityProvider>();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user