q

package module
v0.0.0-...-823f4ce Latest Latest
Warning

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

Go to latest
Published: Jan 4, 2024 License: Apache-2.0 Imports: 8 Imported by: 1

README

Q

GoDoc

Q is a simple persistent message/task queue. It is written in Golang.

It has the following features:

Messages in Q are very safe. They exist until the consumer confirms clearly, otherwise messages would be recycled and added back to queue again.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Queue

type Queue struct {
	Path string `json:"path"`
	// contains filtered or unexported fields
}

func NewQueue

func NewQueue(path string) (*Queue, error)

func NewQueueWithRetryLimit

func NewQueueWithRetryLimit(path string, limit int) (*Queue, error)

func (*Queue) Close

func (q *Queue) Close()

func (*Queue) Confirm

func (q *Queue) Confirm(key string) error

func (*Queue) Dequeue

func (q *Queue) Dequeue(timeout int64) (string, string, error)

func (*Queue) Drop

func (q *Queue) Drop()

func (*Queue) Enqueue

func (q *Queue) Enqueue(data string) error

func (*Queue) Peek

func (q *Queue) Peek() (string, error)

func (*Queue) Status

func (q *Queue) Status() map[string]interface{}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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