unistore: add timeout config for resource server joining the ring (#112392)

Signed-off-by: Maicon Costa <maiconscosta@gmail.com>
This commit is contained in:
maicon
2025-10-14 15:27:08 -04:00
committed by GitHub
parent 507720e601
commit 3d112755de
4 changed files with 8 additions and 1 deletions
@@ -314,6 +314,11 @@ func createStorageServerApi(t *testing.T, instanceId int, dbType, dbConnStr stri
cfg.IndexPath = t.TempDir() + cfg.InstanceID
cfg.IndexFileThreshold = testIndexFileThreshold
cfg.Target = []string{modules.StorageServer}
// make sure the resource server has enough time to join the ring
// before the tests start sending traffic
// otherwise the tests will be flaky,
// also, tests are going to timeout after 300 seconds anyway
cfg.ResourceServerJoinRingTimeout = 300 * time.Second
return initModuleServerForTest(t, cfg, Options{}, api.ServerOptions{})
}