balancer

package
v0.10.3-0...-843c1f5 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewBalancerBuilder

func NewBalancerBuilder(name string, pb PickerBuilder, config base.Config) balancer.Builder

NewBalancerBuilder returns a base balancer builder configured by the provided config.

Types

type PickerBuildInfo

type PickerBuildInfo struct {
	// ReadySCs is a map from all ready SubConns to the Addresses can be used.
	ReadySCs map[balancer.SubConn]base.SubConnInfo

	// UnReadySCs is a map from all unready SubConns to the Addresses can be used.
	UnReadySCs map[balancer.SubConn]base.SubConnInfo
}

type PickerBuilder

type PickerBuilder interface {
	// Build returns a picker that will be used by gRPC to pick a SubConn.
	Build(info PickerBuildInfo) balancer.Picker
}

PickerBuilder creates balancer.Picker.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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