inmem

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Jul 5, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package inmem provides an in-process Transport driver. It is intended for unit tests, examples, and single-binary deployments. It is not safe for cross-process communication.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Driver

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

Driver is an in-memory pub/sub broker.

func New

func New() *Driver

New constructs an empty in-memory driver.

func (*Driver) Capabilities

func (*Driver) Capabilities() transport.Capabilities

func (*Driver) Close

func (d *Driver) Close() error

func (*Driver) Connect

func (*Driver) Connect(context.Context) error

func (*Driver) OpenInbox

func (d *Driver) OpenInbox(ctx context.Context) (transport.Inbox, error)

func (*Driver) Publish

func (d *Driver) Publish(ctx context.Context, msg *transport.RawMessage) error

func (*Driver) Request

func (d *Driver) Request(ctx context.Context, msg *transport.RawMessage) (*transport.RawMessage, error)

func (*Driver) Subscribe

func (d *Driver) Subscribe(_ context.Context, subject, queue string, h transport.Handler) (transport.Subscription, error)

Jump to

Keyboard shortcuts

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