added channels to make faster termination