// Retrieve The error messages created during secondary DNS record transfer.
494444
func (r Dns_Secondary) GetErrorMessages() (resp []datatypes.Dns_Message, err error) {
	err = r.Session.DoRequest("SoftLayer_Dns_Secondary", "getErrorMessages", nil, &r.Options, &resp)
	return
}
45478
func (obj *Global) GetOdbcDsns(ctx context.Context) ([]*OdbcDsn, error) {
	result := &struct {
		OdbcDsns []*OdbcDsn	`json:"qOdbcDsns"`
	} {}
	err := obj.rpc(ctx, "GetOdbcDsns", result)
	return result.OdbcDsns, err 
}
976167
func (c *openstackCloud) ListDNSRecordsets(zoneID string, opt recordsets.ListOptsBuilder) ([]recordsets.RecordSet, error) {
	var rrs []recordsets.RecordSet

	done, err := vfs.RetryWithBackoff(readBackoff, func() (bool, error) {
		allPages, err := recordsets.ListByZone(c.dnsClient, zoneID, opt).AllPages()
		if err != nil {
			return false, fmt.Errorf("failed to list dns recordsets: %s", err)
		}
		r, err := recordsets.ExtractRecordSets(allPages)
		if err != nil {
			return false, fmt.Errorf("failed to extract dns recordsets pages: %s", err)
		}
		rrs = r
		return true, nil
	})
	if err != nil {
		return rrs, err
	} else if done {
		return rrs, nil
	} else {
		return rrs, wait.ErrWaitTimeout
	}
}
1204300
func (c *Client) GetRecordID(domainID, recordName, recordType, data string) (string, error) {
	recordList := &RecordListResponse{}

	err := c.do(http.MethodGet, fmt.Sprintf("/v1/domains/%s/records", domainID), nil, recordList)
	if err != nil {
		return "", err
	}

	for _, record := range recordList.Records {
		if record.Name == recordName && record.Type == recordType && record.Data == data {
			return record.ID, nil
		}
	}
	return "", errors.New("no such record")
}
723247
func (client *Client) GetRecordsWithFilters(ctx context.Context, domain, name, recordType string) ([]DNSRecord, error) {

	filters := url.Values{}
	if name != "" {
		filters.Add("name", name)
	}
	if recordType != "" {
		filters.Add("record_type", recordType)
	}

	resp, err := client.dnsRequest(ctx, "/v1/domains/"+domain+"/records", filters, "", "GET")
	if err != nil {
		return nil, err
	}

	var r []DNSRecordResponse
	if err = json.Unmarshal(resp, &r); err != nil {
		return nil, err
	}

	records := make([]DNSRecord, 0, len(r))
	for _, rec := range r {
		records = append(records, rec.Record)
	}

	return records, nil
}
1064357
func (s *APIServer) getTunnelConnections(auth ClientI, w http.ResponseWriter, r *http.Request, p httprouter.Params, version string) (interface{}, error) {
	conns, err := auth.GetTunnelConnections(p.ByName("cluster"))
	if err != nil {
		return nil, trace.Wrap(err)
	}
	items := make([]json.RawMessage, len(conns))
	for i, conn := range conns {
		data, err := services.MarshalTunnelConnection(conn, services.WithVersion(version), services.PreserveResourceID())
		if err != nil {
			return nil, trace.Wrap(err)
		}
		items[i] = data
	}
	return items, nil
}
339749
func (c *Client) GetDNSReverse(ctx context.Context, ip []net.IP) (map[string]*[]string, error) {
	ips := make([]string, 0)

	for _, ipAddress := range ip {
		ips = append(ips, ipAddress.String())
	}

	dnsReversed := make(map[string]*[]string)
	params := struct {
		IP string `url:"ips"`
	}{strings.Join(ips, ",")}

	req, err := c.NewRequest("GET", reversePath, params, nil)
	if err != nil {
		return nil, err
	}

	if err := c.Do(ctx, req, &dnsReversed); err != nil {
		return nil, err
	}

	return dnsReversed, nil
}
499991
func GetMessage(err interface{}) string {
	switch e := err.(type) {
	case DropboxError:
		return extractFullErrorMessage(e, false)
	case runtime.Error:
		return runtime.Error(e).Error()
	case error:
		return e.Error()
	default:
		return "Passed a non-error to GetMessage"
	}
}
1161690
func CollectErrorMessages(err error, in []string) (out []string) {
	out = in
	if err == nil {
		return
	}

	if err == auth.ErrLoginRequired {
		out = append(out, "Need to login first by running:\nlucicfg auth-login")
		return
	}

	switch e := err.(type) {
	case lucicfg.BacktracableError:
		out = append(out, e.Backtrace())
	case errors.MultiError:
		for _, inner := range e {
			out = CollectErrorMessages(inner, out)
		}
	default:
		out = append(out, fmt.Sprintf("Error: %s", err))
	}
	return
}
741920
func errorFunc(server string, w dns.ResponseWriter, r *dns.Msg, rc int) {
	state := request.Request{W: w, Req: r}

	answer := new(dns.Msg)
	answer.SetRcode(r, rc)
	state.SizeAndDo(answer)

	w.WriteMsg(answer)
}
369877
func (aer *AllErrorRecorder) GetErrors() []error {
	aer.mu.Lock()
	defer aer.mu.Unlock()
	return aer.Errors
}
601661
func (d *DNSProvider) getZoneRecords(name string, zone *Zone) ([]Record, error) {
	u := fmt.Sprintf("/zones/%s/records", zone.ID)
	req, err := d.newRequest(http.MethodGet, u, nil)
	if err != nil {
		return nil, err
	}

	query := req.URL.Query()
	query.Add("page_request.filter", fmt.Sprintf("name='%s' and type='TXT'", name))
	req.URL.RawQuery = query.Encode()

	var records Records
	err = d.do(req, &records)
	if err != nil {
		return nil, err
	}

	if len(records.Records) == 0 {
		return nil, fmt.Errorf("did not find record with name %s", name)
	}

	return records.Records, nil
}
1347368
func (r *Request) ErrorMessage(rcode int) *dns.Msg {
	m := new(dns.Msg)
	m.SetRcode(r.Req, rcode)
	return m
}
150994
func (c *Connection) retrieveMessageIDs() (err error) {
	t := time.Now()

	msgs := api.GetRegisteredMessages()

	var n int
	for name, msg := range msgs {
		msgID, err := c.GetMessageID(msg)
		if err != nil {
			log.Debugf("retrieving msgID for %s failed: %v", name, err)
			continue
		}
		n++

		if c.pingReqID == 0 && msg.GetMessageName() == msgControlPing.GetMessageName() {
			c.pingReqID = msgID
			msgControlPing = reflect.New(reflect.TypeOf(msg).Elem()).Interface().(api.Message)
		} else if c.pingReplyID == 0 && msg.GetMessageName() == msgControlPingReply.GetMessageName() {
			c.pingReplyID = msgID
			msgControlPingReply = reflect.New(reflect.TypeOf(msg).Elem()).Interface().(api.Message)
		}

		if debugMsgIDs {
			log.Debugf("message %q (%s) has ID: %d", name, getMsgNameWithCrc(msg), msgID)
		}
	}
	log.Debugf("retrieved %d/%d msgIDs (took %s)", n, len(msgs), time.Since(t))

	return nil
}
937128
func (_class VMGuestMetricsClass) GetAllRecords(sessionID SessionRef) (_retval map[VMGuestMetricsRef]VMGuestMetricsRecord, _err error) {
	_method := "VM_guest_metrics.get_all_records"
	_sessionIDArg, _err := convertSessionRefToXen(fmt.Sprintf("%s(%s)", _method, "session_id"), sessionID)
	if _err != nil {
		return
	}
	_result, _err := _class.client.APICall(_method, _sessionIDArg)
	if _err != nil {
		return
	}
	_retval, _err = convertVMGuestMetricsRefToVMGuestMetricsRecordMapToGo(_method + " -> ", _result.Value)
	return
}
376562
func (this *SiestaClient) GetErrorType(err error) ErrorType {
	switch {
	case err == siesta.ErrOffsetOutOfRange:
		return ErrorTypeOffsetOutOfRange
	case err == siesta.ErrEOF:
		return ErrorTypeCorruptedResponse
	default:
		return ErrorTypeOther
	}
}
809354
func (d *domainClient) GetHistograms(ctx context.Context, args *GetHistogramsArgs) (reply *GetHistogramsReply, err error) {
	reply = new(GetHistogramsReply)
	if args != nil {
		err = rpcc.Invoke(ctx, "Browser.getHistograms", args, reply, d.conn)
	} else {
		err = rpcc.Invoke(ctx, "Browser.getHistograms", nil, reply, d.conn)
	}
	if err != nil {
		err = &internal.OpError{Domain: "Browser", Op: "GetHistograms", Err: err}
	}
	return
}