in metricsgenreceiver/config.go [53:71]
func (cfg *Config) Validate() error {
if cfg.Interval.Seconds() < 1 {
return fmt.Errorf("the interval has to be set to at least 1 second (1s)")
}
if cfg.StartTime.After(cfg.EndTime) {
return fmt.Errorf("start_time must be before end_time")
}
for _, scn := range cfg.Scenarios {
if scn.Concurrency != 0 && scn.Scale%scn.Concurrency != 0 {
return fmt.Errorf("scale must be a multiple of concurrency")
}
if scn.Concurrency < 0 {
return fmt.Errorf("concurrency must be a positive number")
}
}
return nil
}