impl

package
v1.0.7 Latest Latest
Warning

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

Go to latest
Published: Dec 24, 2020 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type NotifierImpl

type NotifierImpl struct {
	pb.UnimplementedNotifierServiceServer

	Subscribers map[string][]*StreamConnection
	ConfigData  *config.Config

	WebServerLocalAddressFunc func() string
	// contains filtered or unexported fields
}

func (*NotifierImpl) Broadcast

func (n *NotifierImpl) Broadcast(c context.Context, d *pb.NotificationData) (r *pb.NotificationDone, err error)

func (*NotifierImpl) ConnectDataStore

func (n *NotifierImpl) ConnectDataStore() error

func (*NotifierImpl) ConnectSNS

func (n *NotifierImpl) ConnectSNS(awsRegionStr awsregion.AWSRegion) (err error)

func (*NotifierImpl) ReadConfig

func (n *NotifierImpl) ReadConfig(appName string, configFileName string, customConfigPath string) error

ReadConfig will read in config data

func (*NotifierImpl) Subscribe

func (*NotifierImpl) Unsubscribe

func (*NotifierImpl) UnsubscribeAllPrior

func (n *NotifierImpl) UnsubscribeAllPrior()

UnsubscribeAllPrior will attempt to clean up all prior subscriptions based in the config

type StreamConnection

type StreamConnection struct {
	Id     string // typically custom created guid or other unique id value, used during unsubscribe
	Topic  string // topic refers to the topic arn
	Stream pb.NotifierService_SubscribeServer
	Active bool
	Err    chan error
}

Jump to

Keyboard shortcuts

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