internal

package
v0.0.0-...-58e6625 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2016 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package internal provides support for the cloud packages.

Users should not import this package directly.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Retry

func Retry(ctx context.Context, bo gax.Backoff, f func() (stop bool, err error)) error

Retry calls the supplied function f repeatedly according to the provided backoff parameters. It returns when one of the following occurs: When f's first return value is true, Retry immediately returns with f's second return value. When the provided context is done, Retry returns with ctx.Err().

Types

type Transport

type Transport struct {

	// Base is the actual http.RoundTripper
	// requests will use. It must not be nil.
	Base http.RoundTripper
}

Transport is an http.RoundTripper that appends Google Cloud client's user-agent to the original request's user-agent header.

func (*Transport) RoundTrip

func (t *Transport) RoundTrip(req *http.Request) (*http.Response, error)

RoundTrip appends a user-agent to the existing user-agent header and delegates the request to the base http.RoundTripper.

Directories

Path Synopsis
Package atomiccache provides a map-based cache that supports very fast reads.
Package atomiccache provides a map-based cache that supports very fast reads.
Package fields provides a view of the fields of a struct that follows the Go rules, amended to consider tags and case insensitivity.
Package fields provides a view of the fields of a struct that follows the Go rules, amended to consider tags and case insensitivity.
Package optional provides versions of primitive types that can be nil.
Package optional provides versions of primitive types that can be nil.
Package pretty implements a simple pretty-printer.
Package pretty implements a simple pretty-printer.
Package testutil contains helper functions for writing tests.
Package testutil contains helper functions for writing tests.

Jump to

Keyboard shortcuts

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