grpc

package
v0.3.0-rc.0 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2019 License: MIT Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type API

API is the gRPC interface for the Dapr gRPC API. It implements both the internal and external proto definitions.

func NewAPI

func NewAPI(daprID string, appChannel channel.AppChannel, stateStore state.Store, pubSub pubsub.PubSub, directMessaging messaging.DirectMessaging, actor actors.Actors, sendToOutputBindingFn func(name string, req *bindings.WriteRequest) error, componentHandler components.ComponentHandler) API

NewAPI returns a new gRPC API

type Manager

type Manager struct {
	AppClient *grpc.ClientConn
	// contains filtered or unexported fields
}

Manager is a wrapper around gRPC connection pooling

func NewGRPCManager

func NewGRPCManager() *Manager

NewGRPCManager returns a new grpc manager

func (*Manager) CreateLocalChannel

func (g *Manager) CreateLocalChannel(port, maxConcurrency int) (channel.AppChannel, error)

CreateLocalChannel creates a new gRPC AppChannel

func (*Manager) GetGRPCConnection

func (g *Manager) GetGRPCConnection(address string) (*grpc.ClientConn, error)

GetGRPCConnection returns a new grpc connection for a given address and inits one if doesn't exist

type Server

type Server interface {
	StartNonBlocking() error
}

Server is an interface for the dapr gRPC server

func NewServer

func NewServer(api API, config ServerConfig, tracingSpec config.TracingSpec) Server

NewServer returns a new gRPC server

type ServerConfig

type ServerConfig struct {
	DaprID      string
	HostAddress string
	Port        int
}

ServerConfig is the config object for a grpc server

func NewServerConfig

func NewServerConfig(daprID string, hostAddress string, port int) ServerConfig

NewServerConfig returns a new grpc server config

Jump to

Keyboard shortcuts

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