code: func (fw *Framework) QuerySrvRecords(records []string) ([]srvcache.Server, error) {
  	servers := []srvcache.Server{}
  
  	if !fw.Config.Choria.UseSRVRecords {
  		return servers, errors.New("SRV lookups are disabled in the configuration file")
  	}
  
  	domain := fw.Config.Choria.SRVDomain
  	var err error
  
  	if fw.Config.Choria.SRVDomain == "" {
  		domain, err = fw.FacterDomain()
  		if err != nil {
  			return servers, err
  		}
  
  		// cache the result to speed things up
  		fw.Config.Choria.SRVDomain = domain
  	}
  
  	for _, q := range records {
  		record := q + "." + domain
  		log.Debugf("Attempting SRV lookup for %s", record)
  
  		cname, addrs, err := srvcache.LookupSRV("", "", record, net.LookupSRV)
  		if err != nil {
  			log.Debugf("Failed to resolve %s: %s", record, err)
  			continue
  		}
  
  		log.Debugf("Found %d SRV records for %s", len(addrs), cname)
  
  		for _, a := range addrs {
  			servers = append(servers, srvcache.Server{Host: strings.TrimRight(a.Target, "."), Port: int(a.Port)})
  		}
  	}
  
  	return servers, nil
  }
docs: // QuerySrvRecords looks for SRV records within the right domain either
  // thanks to facter domain or the configured domain.
  //
  // If the config disables SRV then a error is returned.