Browse Source

e2e: generate keys for more stable load (#7344)

pull/7356/head
Sam Kleinman 3 years ago
committed by GitHub
parent
commit
babd3acb70
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions
  1. +3
    -3
      test/e2e/runner/load.go

+ 3
- 3
test/e2e/runner/load.go View File

@ -97,9 +97,9 @@ func loadGenerate(ctx context.Context, r *rand.Rand, chTx chan<- types.Tx, txSiz
case <-timer.C:
}
// We keep generating the same 100 keys over and over, with different values.
// This gives a reasonable load without putting too much data in the app.
id := rand.Int63() % 100 // nolint: gosec
// Constrain the key space to avoid using too much
// space, while reduce the size of the data in the app.
id := r.Int63n(100)
bz := make([]byte, txSize)
_, err := r.Read(bz)


Loading…
Cancel
Save