go: cloud.google.com/go/bigtable/internal/gax Index | Files

package gax

import "cloud.google.com/go/bigtable/internal/gax"

This is ia snapshot from github.com/googleapis/gax-go with minor modifications.

This is ia snapshot from github.com/googleapis/gax-go with minor modifications.


Package Files

call_option.go invoke.go

func Invoke Uses

func Invoke(ctx context.Context, stub APICall, opts ...CallOption) error

Invoke calls stub with a child of context modified by the specified options.

type APICall Uses

type APICall func(context.Context) error

A user defined call stub.

type BackoffSettings Uses

type BackoffSettings struct {
    DelayTimeoutSettings MultipliableDuration
    RPCTimeoutSettings   MultipliableDuration

Parameters to the exponential backoff algorithm for retrying.

type CallOption Uses

type CallOption interface {

func WithDelayTimeoutSettings Uses

func WithDelayTimeoutSettings(initial time.Duration, max time.Duration, multiplier float64) CallOption

WithDelayTimeoutSettings specifies: - The initial delay time, in milliseconds, between the completion of

the first failed request and the initiation of the first retrying

- The multiplier by which to increase the delay time between the

completion of failed requests, and the initiation of the subsequent
retrying request.

- The maximum delay time, in milliseconds, between requests. When this

value is reached, `RetryDelayMultiplier` will no longer be used to
increase delay time.

func WithRetryCodes Uses

func WithRetryCodes(retryCodes []codes.Code) CallOption

WithRetryCodes sets a list of Google API canonical error codes upon which a retry should be attempted.

type CallSettings Uses

type CallSettings struct {
    Timeout       time.Duration
    RetrySettings RetrySettings

Encapsulates the call settings for a particular API call.

func (CallSettings) Resolve Uses

func (w CallSettings) Resolve(s *CallSettings)

type MultipliableDuration Uses

type MultipliableDuration struct {
    Initial    time.Duration
    Max        time.Duration
    Multiplier float64

type RetrySettings Uses

type RetrySettings struct {
    RetryCodes      map[codes.Code]bool
    BackoffSettings BackoffSettings

Per-call configurable settings for retrying upon transient failure.

Package gax imports 7 packages (graph) and is imported by 1 packages. Updated 2017-05-27. Refresh now. Tools for package owners.