Skip to content

Client.Request does not respect custom http.Client timeout (Kubernetes controller) #3

@francescobianco

Description

@francescobianco

Description
While integrating in a Kubernetes controller (using controller-runtime), requests hang indefinitely despite setting timeouts.

Code snippet

httpClient := &http.Client{
    Timeout: 5 * time.Second,
}

apiClient := client.NewClient(token)

_, err := apiClient.Request(ctx, "GET", baseURL, "/advance", nil, nil)

Issue
SDK does not allow injecting custom http.Client.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions