code: func (g *gossipServiceImpl) Stop() {
  	if g.toDie() {
  		return
  	}
  	atomic.StoreInt32(&g.stopFlag, int32(1))
  	g.logger.Info("Stopping gossip")
  	g.chanState.stop()
  	g.discAdapter.close()
  	g.disc.Stop()
  	g.certStore.stop()
  	g.toDieChan <- struct{}{}
  	g.emitter.Stop()
  	g.ChannelDeMultiplexer.Close()
  	g.stateInfoMsgStore.Stop()
  	g.stopSignal.Wait()
  	g.comm.Stop()
  }
docs: // Stop stops the gossip component