apiclientconfig

package
v0.42.2 Latest Latest
Warning

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

Go to latest
Published: Jul 26, 2024 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (

	// DialTimeoutDefault is a default dial timeout of FrostFS API client connection.
	DialTimeoutDefault = 5 * time.Second

	// StreamTimeoutDefault is a default timeout of FrostFS API streaming operation.
	StreamTimeoutDefault = 15 * time.Second
)

Variables

This section is empty.

Functions

func AllowExternal

func AllowExternal(c *config.Config) bool

AllowExternal returns the value of "allow_external" config parameter from "apiclient" section.

Returns false if the value is missing or invalid.

func DialTimeout

func DialTimeout(c *config.Config) time.Duration

DialTimeout returns the value of "dial_timeout" config parameter from "apiclient" section.

Returns DialTimeoutDefault if the value is not positive duration.

func ReconnectTimeout

func ReconnectTimeout(c *config.Config) time.Duration

ReconnectTimeout returns the value of "reconnect_timeout" config parameter from "apiclient" section.

Returns 0 if the value is not positive duration.

func StreamTimeout

func StreamTimeout(c *config.Config) time.Duration

StreamTimeout returns the value of "stream_timeout" config parameter from "apiclient" section.

Returns DialTimeoutDefault if the value is not positive duration.

Types

This section is empty.

Jump to

Keyboard shortcuts

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