From 3206499572a6f84616a5901c5e4f07866a9dc910 Mon Sep 17 00:00:00 2001 From: Nathan VanBenschoten Date: Sun, 23 Jun 2024 22:36:30 -0400 Subject: [PATCH] roachtest: improve logging in gossip/chaos/nodes=9 further Informs #124828. Informs #126077. Release note: None --- pkg/cmd/roachtest/tests/gossip.go | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/pkg/cmd/roachtest/tests/gossip.go b/pkg/cmd/roachtest/tests/gossip.go index ed820bfadac2..d90f688af99d 100644 --- a/pkg/cmd/roachtest/tests/gossip.go +++ b/pkg/cmd/roachtest/tests/gossip.go @@ -120,14 +120,17 @@ SELECT node_id } waitForGossip := func(deadNode int) { - t.Status("waiting for gossip to exclude dead node %d", deadNode) + t.Status(fmt.Sprintf("waiting for gossip to exclude dead node %d", deadNode)) start := timeutil.Now() for { - t.L().Printf("checking if gossip excludes dead node %d\n", deadNode) + t.L().Printf("checking if gossip excludes dead node %d (%.0fs)\n", + deadNode, timeutil.Since(start).Seconds()) if gossipOK(start, deadNode) { return } - time.Sleep(time.Second) + const sleepDur = 1 * time.Second + t.L().Printf("sleeping for %s (%.0fs)\n", sleepDur, timeutil.Since(start).Seconds()) + time.Sleep(sleepDur) } }