feat(site): DeploymentManagerActor fetches config then applies (notify-and-fetch)
This commit is contained in:
@@ -839,6 +839,12 @@ akka {{
|
||||
|
||||
_logger.LogInformation("SiteReplicationActor created and S&F replication handler wired");
|
||||
|
||||
// Notify-and-fetch (Task 10): the active singleton fetches a deployment's
|
||||
// flattened config from central over HTTP when a RefreshDeploymentCommand
|
||||
// arrives. Resolve the fetcher from the same provider the actor already uses.
|
||||
var deploymentConfigFetcher =
|
||||
_serviceProvider.GetService<ZB.MOM.WW.ScadaBridge.SiteRuntime.Deployment.IDeploymentConfigFetcher>();
|
||||
|
||||
// Create the Deployment Manager as a cluster singleton
|
||||
var singletonProps = ClusterSingletonManager.Props(
|
||||
singletonProps: Props.Create(() => new DeploymentManagerActor(
|
||||
@@ -851,7 +857,9 @@ akka {{
|
||||
dclManager,
|
||||
replicationActor,
|
||||
siteHealthCollector,
|
||||
_serviceProvider)),
|
||||
_serviceProvider,
|
||||
null,
|
||||
deploymentConfigFetcher)),
|
||||
terminationMessage: PoisonPill.Instance,
|
||||
settings: ClusterSingletonManagerSettings.Create(_actorSystem!)
|
||||
.WithRole(siteRole)
|
||||
|
||||
Reference in New Issue
Block a user