removed waitgroup/pubchannel; added stoppablelistener