add detach option for stop_workers method