gateway

package
v0.0.0-...-0e8e39a Latest Latest
Warning

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

Go to latest
Published: May 15, 2021 License: MIT Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrIncorrectResponseType = errors.New("incorrect response type")

ErrIncorrectResponseType is the error returned when a collection method is called and Raft returned unexpected response type.

ErrNotLeader is the error returned in case of a Raft follower call.

Functions

This section is empty.

Types

type Gateway

type Gateway = errgroup.Group

Gateway processes external requests.

func New

func New(ctx context.Context, cluster cluster.Cluster, opts ...Option) (*Gateway, error)

New creates new Gateway instance

type Option

type Option func(*options)

Option defines a Gateway configuration option.

func WithGRPCPort

func WithGRPCPort(v int) Option

func WithHTTPPort

func WithHTTPPort(v int) Option

func WithListenAddress

func WithListenAddress(v string) Option

func WithLoggerName

func WithLoggerName(v string) Option

func WithMetricsEnabled

func WithMetricsEnabled(v bool) Option

func WithPprofEnabled

func WithPprofEnabled(v bool) Option

Jump to

Keyboard shortcuts

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