memory

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2020 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package memory provides a message broker using memory.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Broker

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

Broker is a memory message broker.

func New

func New() *Broker

New return new memory broker.

func (*Broker) HealthCheck

func (br *Broker) HealthCheck() health.CheckFunc

HealthCheck implements broker.Broker interface.

func (*Broker) Publish

func (br *Broker) Publish(topic string, m *broker.Message, opts ...broker.PublishOption) error

Publish implements broker.Broker interface.

func (*Broker) Subscribe

func (br *Broker) Subscribe(topic string, h broker.Handler, opts ...broker.SubscribeOption) (broker.Subscriber, error)

Subscribe implements broker.Broker interface.

Jump to

Keyboard shortcuts

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