poolCfg

package
v0.0.0-...-fc8e49a Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Logger logger.LoggerInterface

	PoolConfig *PoolConfig `json:"pool_config"`
}

func InitConfig

func InitConfig(options ...Option) *Config

func NewDefaultConfig

func NewDefaultConfig() *Config

type Option

type Option func(c *Config)

func WithConnectorHandler

func WithConnectorHandler(connectorHandler connector.Handler) Option

func WithDiscovery

func WithDiscovery(discovery discovery.Discovery) Option

func WithLogger

func WithLogger(logger logger.LoggerInterface) Option

func WithPoolChanSize

func WithPoolChanSize(chanSize int) Option

func WithPoolSendChanTimeout

func WithPoolSendChanTimeout(sendChanTimeout time.Duration) Option

type PoolConfig

type PoolConfig struct {
	SendChanTimeout  time.Duration       `json:"send_chan_timeout"`
	ChanSize         int                 `json:"chan_size"`
	Discovery        discovery.Discovery `json:"-"`
	ConnectorHandler connector.Handler   `json:"-"`
}

Jump to

Keyboard shortcuts

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