profile

package
Version: v1.0.276 Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2021 License: Apache-2.0 Imports: 2 Imported by: 1,806

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExponentialBackoff added in v1.0.211

func ExponentialBackoff(index int) time.Duration

Types

type ClientProfile

type ClientProfile struct {
	HttpProfile *HttpProfile
	// Valid choices: HmacSHA1, HmacSHA256, TC3-HMAC-SHA256.
	// Default value is TC3-HMAC-SHA256.
	SignMethod      string
	UnsignedPayload bool
	// Valid choices: zh-CN, en-US.
	// Default value is zh-CN.
	Language string
	Debug    bool
	// define Whether to enable Regional auto switch
	DisableRegionBreaker bool
	BackupEndPoint       string
	// define how to retry request
	NetworkFailureMaxRetries       int
	NetworkFailureRetryDuration    DurationFunc
	RateLimitExceededMaxRetries    int
	RateLimitExceededRetryDuration DurationFunc
}

func NewClientProfile

func NewClientProfile() *ClientProfile

type DurationFunc added in v1.0.211

type DurationFunc func(index int) time.Duration

func ConstantDurationFunc added in v1.0.211

func ConstantDurationFunc(duration time.Duration) DurationFunc

type HttpProfile

type HttpProfile struct {
	ReqMethod  string
	ReqTimeout int
	Scheme     string
	RootDomain string
	Endpoint   string
	// Deprecated, use Scheme instead
	Protocol string
}

func NewHttpProfile

func NewHttpProfile() *HttpProfile

Jump to

Keyboard shortcuts

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