MSP-4622 configuration division

This commit is contained in:
Парусов Павел Андреевич committed 2025-01-16 14:11:58 +03:00
1 parent cf9a24f424
commit 2c0562e98f
9 files changed
+164 -18

No files matched your search

+4 -1
View File
@@ -48,7 +48,10 @@ func (a *Assembly) ReceiveConfig(ctx context.Context, remoteConfig []byte) error
a.logger.SetLevel(newCfg.LogLevel)
locator := NewLocator(a.logger, a.router)
handler := locator.Handler(newCfg)
handler, err := locator.Handler(newCfg)
if err != nil {
a.logger.Fatal(ctx, errors.WithMessage(err, "new handler"))
}
a.server.Upgrade(handler)