publisher

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: May 24, 2021 License: CC0-1.0 Imports: 8 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Publisher

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

Publisher - Abstraction layer at which publisher operates

func New

func New(ctx context.Context, proto, addr string) (*Publisher, error)

New - New publisher instance, attempts to establish connection with remote & returns handle with open connection, ready for use

func (*Publisher) Connected

func (p *Publisher) Connected() bool

Connected - Concurrent safe check for connection aliveness with HUB

func (*Publisher) Publish

func (p *Publisher) Publish(msg *ops.Msg) (uint64, error)

Publish - Sends message publish request over network, returns back how many of subscribers received this message

Jump to

Keyboard shortcuts

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