diff options
author | pg9182 <96569817+pg9182@users.noreply.github.com> | 2023-03-04 01:04:50 -0500 |
---|---|---|
committer | pg9182 <96569817+pg9182@users.noreply.github.com> | 2023-03-04 01:04:50 -0500 |
commit | c7bf685c325f944029226351fe6de6bd6cc2ceb8 (patch) | |
tree | c78415f0f3b43f6558240dcaffe1f0ad7bfe1c51 | |
parent | b9afda073e733d19080b42ab3e1f1398b5dceb44 (diff) | |
download | Atlas-c7bf685c325f944029226351fe6de6bd6cc2ceb8.tar.gz Atlas-c7bf685c325f944029226351fe6de6bd6cc2ceb8.zip |
pkg/api/api0/api0testutil: Reduce db stress test concurrency on non-Linux
GitHub Actions workers have gotten noticeably slower, making the
tests much flakier (especially on Windows). And, our main target is
Linux anyways.
-rw-r--r-- | pkg/api/api0/api0testutil/storage.go | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/pkg/api/api0/api0testutil/storage.go b/pkg/api/api0/api0testutil/storage.go index a32de6d..78c123e 100644 --- a/pkg/api/api0/api0testutil/storage.go +++ b/pkg/api/api0/api0testutil/storage.go @@ -180,7 +180,9 @@ func TestAccountStorage(t *testing.T, s api0.AccountStorage) { users uint64 = 16384 ) if runtime.GOOS != "linux" { - concurrency = 16 // doesn't perform as well for database locking, and it's not our primary target anyways + // doesn't perform as well for database locking (esp Windows), and it's not our primary target anyways + concurrency /= 4 + users /= 4 } var wg sync.WaitGroup var fail atomic.Int32 @@ -512,7 +514,9 @@ func TestPdataStorage(t *testing.T, s api0.PdataStorage) { users uint64 = 16384 ) if runtime.GOOS != "linux" { - concurrency = 16 // doesn't perform as well for database locking, and it's not our primary target anyways + // doesn't perform as well for database locking (esp Windows), and it's not our primary target anyways + concurrency /= 4 + users /= 4 } var wg sync.WaitGroup var fail atomic.Int32 |