특정 시나리오벼로 timeSleep

main
JungJun 2 years ago
parent 5bf76f0a5d
commit f941e9205a

@ -287,8 +287,9 @@ func (s *ScenarioSession) BOTPFunc(w http.ResponseWriter, r *http.Request) {
}
l.Printf(icslog.LOG_LEVEL_INFO, -1, "Send Message\n %s", string(resMarshal))
if conf.TimeSleep.Value {
time.Sleep(time.Second * time.Duration(time.Duration(conf.TimeSleep.TimeSleep)))
if scnarioConf.TimeValue[s.session[request.Token].Count] {
l.Printf(icslog.LOG_LEVEL_INFO, -1, "Time Sleep %d \r\n", scnarioConf.TimeSleep[s.session[request.Token].Count])
time.Sleep(time.Second * time.Duration(time.Duration(scnarioConf.TimeSleep[s.session[request.Token].Count])))
}
// send response

Loading…
Cancel
Save