api operations idempotent
This commit is contained in:
parent
2a0b14e03d
commit
7a5cb35c80
@ -63,9 +63,11 @@ func (t *trackingService) StartPipeline(cols ...CollectorType) (string, error) {
|
|||||||
return "RECORDING", errors.New(txt)
|
return "RECORDING", errors.New(txt)
|
||||||
}
|
}
|
||||||
if t.opMode == LIVE {
|
if t.opMode == LIVE {
|
||||||
logrus.Warn("trackingservice: stop current running stream/record before creating new one")
|
txt := "trackingservice: stop current running stream before creating new one"
|
||||||
t.StopAll()
|
logrus.Warn(txt)
|
||||||
|
//t.StopAll()
|
||||||
//time.Sleep(1000 * time.Millisecond)
|
//time.Sleep(1000 * time.Millisecond)
|
||||||
|
return "record already running since: " + t.current.TimeCreated.String(), errors.New(txt)
|
||||||
}
|
}
|
||||||
logrus.Debug("new tracking:", cols)
|
logrus.Debug("new tracking:", cols)
|
||||||
t.opMode = LIVE
|
t.opMode = LIVE
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user