stan

package
v0.0.0-...-edeb7e2 Latest Latest
Warning

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

Go to latest
Published: May 5, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BrokerPeer

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

BrokerPeer implements the peer interface for AMQP brokers

func NewBrokerPeer

func NewBrokerPeer(settings broker.MQSettings) *BrokerPeer

NewPeer creates and returns a new Peer for communicating with Kafka

func (*BrokerPeer) GetResults

func (bp *BrokerPeer) GetResults() *broker.Results

func (*BrokerPeer) SetupPublishers

func (bp *BrokerPeer) SetupPublishers() error

func (*BrokerPeer) SetupSubscribers

func (bp *BrokerPeer) SetupSubscribers() error

func (*BrokerPeer) StartPublishers

func (bp *BrokerPeer) StartPublishers()

func (*BrokerPeer) StartSubscribers

func (bp *BrokerPeer) StartSubscribers()

func (*BrokerPeer) Teardown

func (bp *BrokerPeer) Teardown()

Performs any broker-connection cleanup after test is done

type Peer

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

Peer stores specific NATS/STAN broker connection information

func (*Peer) ACKHandler

func (p *Peer) ACKHandler()

ACKhandler for produced messages

func (*Peer) DoneChannel

func (p *Peer) DoneChannel()

DoneChannel signals to the peer that message publishing has completed.

func (*Peer) ErrorChannel

func (p *Peer) ErrorChannel() <-chan error

ErrorChannel returns the channel on which the peer sends publish errors.

func (*Peer) ReceiveMessage

func (p *Peer) ReceiveMessage() ([]byte, error)

func (*Peer) SendChannel

func (p *Peer) SendChannel() chan<- []byte

Send returns a channel on which messages can be sent for publishing.

func (*Peer) SetupPublishRoutine

func (p *Peer) SetupPublishRoutine()

Goroutine which fetch messages from send-channel and publish them

func (*Peer) SetupPublisherConnection

func (p *Peer) SetupPublisherConnection(connectionURL string) error

func (*Peer) SetupSubscriberConnection

func (p *Peer) SetupSubscriberConnection(connectionURL string) error

Jump to

Keyboard shortcuts

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