From b82b46eb02e85df6bb3f71258437dad18a3313ec Mon Sep 17 00:00:00 2001 From: quobix Date: Tue, 24 Oct 2023 18:17:15 -0400 Subject: [PATCH] =?UTF-8?q?Pipeline=20is=20failing=20because=20it=E2=80=99?= =?UTF-8?q?s=20hanging=20somewhere?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit cannot re-create the problem locally, even when setting GOMAXPROCS to 1 Signed-off-by: quobix --- index/rolodex_remote_loader.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/index/rolodex_remote_loader.go b/index/rolodex_remote_loader.go index f155678a..8605e529 100644 --- a/index/rolodex_remote_loader.go +++ b/index/rolodex_remote_loader.go @@ -260,9 +260,9 @@ func (i *RemoteFS) Open(remoteURL string) (fs.File, error) { // if we're processing, we need to block and wait for the file to be processed // try path first if _, ok := i.ProcessingFiles.Load(remoteParsedURL.Path); ok { - // we can't block if we only have a single CPU, as we'll deadlock, only when we're running in parallel + // we can't block if we only have a couple of CPUs, as we'll deadlock / run super slow, only when we're running in parallel // can we block threads. - if runtime.GOMAXPROCS(-1) > 1 { + if runtime.GOMAXPROCS(-1) > 2 { i.logger.Debug("waiting for existing fetch to complete", "file", remoteURL, "remoteURL", remoteParsedURL.String()) for { if wf, ko := i.Files.Load(remoteParsedURL.Path); ko {