grpc

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GrpcSource

type GrpcSource struct {
	// contains filtered or unexported fields
}

GrpcSource grpc configuration source

func NewGrpcSource

func NewGrpcSource(opts ...Option) *GrpcSource

NewGrpcSource create configuration source from grpc

func (*GrpcSource) Get

func (g *GrpcSource) Get(key string) (*config4live.Config, error)

Get call grpc findConfig by key

type Option

type Option func(s *GrpcSource)

Option the grpc source options

func WithHystrixCommandName

func WithHystrixCommandName(commandName string) Option

WithHystrixCommandName set hystrix command name

func WithHystrixErrorPercentThreshold

func WithHystrixErrorPercentThreshold(errorPercent int) Option

WithHystrixErrorPercentThreshold set hystrix error_percent_threshold

func WithHystrixMaxConcurrentRequests

func WithHystrixMaxConcurrentRequests(maxRequest int) Option

WithHystrixMaxConcurrentRequests set hystrix max_concurrent_requests

func WithHystrixRequestVolumeThreshold

func WithHystrixRequestVolumeThreshold(requestVolume int) Option

WithHystrixRequestVolumeThreshold set hystrix request_volume_threshold

func WithHystrixSleepWindow

func WithHystrixSleepWindow(sleepWindow int) Option

WithHystrixSleepWindow set hystrix sleep_window

func WithHystrixTimeout

func WithHystrixTimeout(timeout int) Option

WithHystrixTimeout set hystrix timeout

func WithURL

func WithURL(url string) Option

WithURL set grpc url

Jump to

Keyboard shortcuts

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