googleclient

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 16, 2026 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package googleclient owns transport policies shared by Google resource clients.

Index

Constants

View Source
const DefaultMaxResponseBytes = 10 * 1024 * 1024

DefaultMaxResponseBytes is the common budget before resource-specific narrowing.

Variables

This section is empty.

Functions

func LogError

func LogError(ctx context.Context, err error, sensitiveValues ...string)

LogError retains provider diagnostics without dumping response bodies or detail payloads.

func NewHTTPClient

func NewHTTPClient(timeout time.Duration, transport http.RoundTripper) *http.Client

NewHTTPClient uses the caller's transport without discovering credentials, retrying requests, or following redirects. Resources own host restrictions and deadlines.

func ReadResponse

func ReadResponse(body io.Reader, limit int64) ([]byte, error)

ReadResponse checks the byte budget before provider decoding. Read errors are left intact for resource retry classification and must be mapped before exposure.

func StatusError

func StatusError(status int) error

StatusError deliberately excludes provider bodies and headers from diagnostics.

func TransportError

func TransportError(ctx context.Context, err error) error

TransportError keeps cancellation and timeouts typed without retaining URLs or credentials.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL