diff options
| author | Will Hawkins <[email protected]> | 2022-11-07 18:27:45 -0500 |
|---|---|---|
| committer | Will Hawkins <[email protected]> | 2022-11-07 18:30:47 -0500 |
| commit | 715e074b068d98bdf466ed33e08a1f54b31c3d44 (patch) | |
| tree | e99397cdb46ad61a52df87ff3b94be6cae99e8b5 | |
| parent | d88338dcf0a53ef48eb0a8064da6e284395f5d29 (diff) | |
[Feature] Allow caller to define rampup interval for load generators.
| -rw-r--r-- | rpm/rpm.go | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -319,6 +319,7 @@ func LoadGenerator( networkActivityCtx context.Context, // Create all network connections in this context. saturationCtx context.Context, // Continue logging, but stop adding flows when this context is canceled! loadGeneratorCtx context.Context, // Stop our activity when we no longer need to generate load. + rampupInterval time.Duration, lgcGenerator func() lgc.LoadGeneratingConnection, // Use this to generate a new load-generating connection. throughputDataLogger datalogger.DataLogger[ThroughputDataPoint], // For logging data! debugging *debug.DebugWithPrefix, // How can we forget debugging? @@ -353,7 +354,7 @@ func LoadGenerator( // the self probes use. Let's send it back to the caller so that they can pass it on if they need to. probeConnectionCommunicationChannel <- lgcs[0] - nextSampleStartTime := time.Now().Add(time.Second) + nextSampleStartTime := time.Now().Add(rampupInterval) for currentInterval := uint64(0); true; currentInterval++ { |
