SigNoz/signoz · error · basemodel.ApiError

couldn't make request: %w

Error message

couldn't make request: %w

What it means

The HTTP client (10s timeout) failed to execute the gateway request: connection refused, DNS failure, TLS error, or timeout. This is the transport-level failure of requestAndParseResponse's client.Do call.

Source

Thrown at ee/query-service/app/api/cloudIntegrations.go:339

	req, err := http.NewRequestWithContext(ctx, reqMethod, url, reqBody)
	if err != nil {
		return nil, basemodel.InternalError(fmt.Errorf(
			"couldn't prepare request: %w", err,
		))
	}

	for k, v := range headers {
		req.Header.Set(k, v)
	}

	client := &http.Client{
		Timeout: 10 * time.Second,
	}

	response, err := client.Do(req)
	if err != nil {
		return nil, basemodel.InternalError(fmt.Errorf("couldn't make request: %w", err))
	}

	defer response.Body.Close()

	respBody, err := io.ReadAll(response.Body)
	if err != nil {
		return nil, basemodel.InternalError(fmt.Errorf("couldn't read response: %w", err))
	}

	var resp ResponseType

	err = json.Unmarshal(respBody, &resp)
	if err != nil {
		return nil, basemodel.InternalError(fmt.Errorf(
			"couldn't unmarshal gateway response into %T", resp,
		))
	}

View on GitHub (pinned to 5069bf80b0)

Solutions

  1. Check the wrapped error for timeout vs refused vs TLS specifics
  2. Verify DNS and egress connectivity to the gateway host from the query-service container
  3. Fix proxy/TLS configuration if indicated
  4. Retry transient failures; investigate slow endpoints if timeouts repeat
Defensive patterns

Strategy: retry

Try / catch

Retry with backoff on network errors, classifying timeouts vs refused vs TLS; stop retrying on permanent TLS/config errors.

Prevention

When it happens

Trigger: Any gateway request when the host is unreachable, DNS cannot resolve the gateway, TLS handshake fails, or the server takes longer than the hardcoded 10-second timeout.

Common situations: Egress firewall/proxy blocking the SigNoz cloud, network flaps, self-signed or expired certificates, or slow upstream responses exceeding the timeout.

Understand the failure class

Background: 'Something went wrong' / 'Request failed (500)' / 'HTTP error! status: 404' — what failed HTTP requests actually mean and how to find the real cause — this error's family across 28 libraries.

Related errors


AI-assisted analysis of SigNoz/signoz@5069bf80b0 (2026-08-28). Data as JSON: /api/errors/a3d50cdbd4ea40aa. Report an issue: GitHub.