Sleep a bit between attempts to connect to the root server

This commit is contained in:
Eelco Dolstra 2024-01-16 15:23:22 +01:00
parent 302625e83b
commit 0b1d93d2ba
1 changed files with 1 additions and 0 deletions

View File

@ -154,6 +154,7 @@ void LocalStore::addTempRoot(const StorePath & path)
if (e.errNo == ECONNREFUSED || e.errNo == ENOENT) {
debug("GC socket connection refused: %s", e.msg());
fdRootsSocket->close();
std::this_thread::sleep_for(std::chrono::milliseconds(100));
goto restart;
}
throw;