google

package
v2.6.1 Latest Latest
Warning

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

Go to latest
Published: May 3, 2022 License: MIT Imports: 18 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GoogleCloud

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

GoogleCloud provides google cloud pubsub

func NewGoogleCloud

func NewGoogleCloud(projectID string) (*GoogleCloud, error)

NewGoogleCloud creates a new GoogleCloud instace for a project

func (*GoogleCloud) Publish

func (g *GoogleCloud) Publish(ctx context.Context, topic string, m *ps.Msg) error

Publish implements Publish

func (*GoogleCloud) Shutdown

func (g *GoogleCloud) Shutdown()

Shutdown shuts down all subscribers gracefully

func (*GoogleCloud) Subscribe

func (g *GoogleCloud) Subscribe(opts ps.HandlerOptions, h ps.MsgHandler)

Subscribe implements Subscribe

Jump to

Keyboard shortcuts

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