carlos / platform Public

feat: alias reconcile rides the fast loop and the instances floor (#151)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Paul Campbell 9b35ef9d9c0bb463050ee4999264f4ec79e6cfd0 parent fb545d3
1 file changed, +9 −3
  • internal/host/agent.go +9 −3
diff --git a/internal/host/agent.go b/internal/host/agent.go
index 9f89b2555..4b4e5f64f 100644
--- a/internal/host/agent.go
+++ b/internal/host/agent.go
@@ -1112,13 +1112,16 @@ func fastConvergeLoop(reg *registry.Registry, svc *activator.Service) {
reg: reg, store: store, pub: pub, optDir: optDir,
restart: restart, passOpts: opts,
// The serial-triggered full pass set, in spec order: mint routes
- // (reconcile), then stage them (adopt), then deliver their config.
- // Each error is one log line, never fatal — the hourly floors stand
- // underneath every leg.
+ // (reconcile), then reconcile aliases, then stage them (adopt), then deliver
+ // their config. Each error is one log line, never fatal — the hourly floors
+ // stand underneath every leg.
fullPass: func(ctx context.Context) {
if err := reconcileSerialized(ctx, store, reg, provisionTickConfig(os.Getenv)); err != nil {
log.Printf("agent: fast converge reconcile: %v", err)
}
+ if err := domains.ReconcileAliases(ctx, store, reg, time.Now); err != nil {
+ log.Printf("agent: fast converge alias pass: %v", err)
+ }
if err := release.Pass(ctx, reg, store, pub, optDir, restart, opts...); err != nil {
log.Printf("agent: fast converge adopt pass: %v", err)
}
@@ -1464,6 +1467,9 @@ func instancesLoop(reg *registry.Registry) {
if err := reconcileSerialized(ctx, store, reg, cfg); err != nil {
log.Printf("agent: instances pass: %v", err)
}
+ if err := domains.ReconcileAliases(ctx, store, reg, time.Now); err != nil {
+ log.Printf("agent: fast converge alias pass: %v", err)
+ }
if !isFleetBox {
if err := ReconcileFleetBindings(ctx, store, reg); err != nil {
log.Printf("agent: fleet bindings reconcile: %v", err)