mirror of
https://github.com/psviderski/uncloud.git
synced 2026-08-26 11:03:34 +00:00
fix: race on cluster init by waiting for corrosion service to become ready with schema applied
This commit is contained in:
@@ -108,11 +108,13 @@ func (cc *clusterController) Run(ctx context.Context) error {
|
||||
if err := cc.corroService.Restart(ctx); err != nil {
|
||||
return fmt.Errorf("restart corrosion service: %w", err)
|
||||
}
|
||||
slog.Info("Corrosion service restarted.")
|
||||
} else {
|
||||
slog.Info("Starting corrosion service.")
|
||||
if err := cc.corroService.Start(ctx); err != nil {
|
||||
return fmt.Errorf("start corrosion service: %w", err)
|
||||
}
|
||||
slog.Info("Corrosion service started.")
|
||||
}
|
||||
|
||||
errGroup, ctx := errgroup.WithContext(ctx)
|
||||
|
||||
Reference in New Issue
Block a user