tsenart / vegeta

HTTP load testing tool and library. It's over 9000!
http://godoc.org/github.com/tsenart/vegeta/lib
MIT License
23.65k stars 1.37k forks source link

Help defining a `SinePacer` to get to target values #714

Open randwom opened 1 month ago

randwom commented 1 month ago

Question

Hi there,

First off, thanks for making such a solid package 💗.

I'm looking to move from a ConstantPacer to a SinePacer but I am struggling to get the inputs right.

My current ConstantPacer does 15000 requests over the course of a minute - so 250 requests a second throughput.

How do I get something similar with SinePacer? Where I:

I.e. Something like this: image

Closest I've figured out is this:

pacer := vegeta.SinePacer{
    Period: time.Minute,
    Mean:   vegeta.Rate{Freq: 126, Per: time.Second},
    Amp:    vegeta.Rate{Freq: 124, Per: time.Second},
}

Many thanks.