queue

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewInMemory

func NewInMemory(logger *zap.Logger) *memoryQueue

func NewNoop

func NewNoop() *noopQueue

Types

type Message

type Message interface {
	// As unmarshals message into the given interface.
	As(interface{}) error
	// Ack marks the message as acknowleged.
	Ack() error
}

type Queue

type Queue interface {
	// Publish publishes a message to the queue.
	Publish(context.Context, names.IncompleteQueueName, interface{}) error
	// Subscribe returns a channel that will receive messages from the queue.
	Subscribe(context.Context, names.IncompleteQueueName, chan<- Message) error
}

Directories

Path Synopsis
enterprise

Jump to

Keyboard shortcuts

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