queue

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Queue

type Queue interface {
	// Put request to queue
	Put(ctx context.Context, request *types.Request) error
	// Peek oldest request or wait till new data arrived/context expiration
	Peek(ctx context.Context) (*types.Request, error)
	// Commit (remove) oldest record
	Commit(ctx context.Context) error
	// Clean all internal allocated resource
	Destroy() error
}

Thread-safe FIFO queue designed for one multiple concurrent writers and single consumer. Queue should store somewhere request body.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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