Sometime, the logstream tasks' latency are high for reasons. The best solution is to restart tasks. But we must make sure related target tasks stop before stop logstream tasks. Are there some bash scripts to restart logstream tasks and related target tasks when latency is higher than 20 min?