code: func (reg *WatchDataReg) Close() error {
  	reg.adapter.access.Lock()
  	defer reg.adapter.access.Unlock()
  
  	for _, sub := range reg.adapter.subscriptions {
  		// subscription should have also change channel, otherwise it is not registered
  		// for change events
  		if sub.ChangeChan != nil && sub.CloseChan != nil {
  			// close the channel with all goroutines under subscription
  			safeclose.Close(sub.CloseChan)
  		}
  	}
  
  	delete(reg.adapter.subscriptions, reg.ResyncName)
  
  	return nil
  }
docs: // Close stops watching of particular KeyPrefixes.