ipc: promote startup socket-wait to a shared DialWait; use in all modules
The cold-start crash-loop wasn't mavweb-specific — mavpoll and mavcaldav also ipc.Dial + exit on failure, so they crash-looped until core booted too. Moved the retry into ipc.DialWait (capped backoff, bounded) and switched mavweb, mavpoll, mavcaldav to it. mavweb's local dialCoreWithRetry is gone. Test: server appears after DialWait starts → it waits and connects. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
+1
-1
@@ -69,7 +69,7 @@ func run(args []string) error {
|
||||
ctx, stop := signal.NotifyContext(context.Background(), syscall.SIGINT, syscall.SIGTERM)
|
||||
defer stop()
|
||||
|
||||
core, err := ipc.Dial(*socket)
|
||||
core, err := ipc.DialWait(*socket, 60*time.Second)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user