queue

package
v0.8.2 Latest Latest
Warning

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

Go to latest
Published: May 25, 2023 License: Apache-2.0, MIT Imports: 7 Imported by: 19

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Queue deprecated

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

Queue provides a best-effort durability, FIFO interface to the datastore for storing cids

Best-effort durability just means that cids in the process of being provided when a crash or shutdown occurs may be in the queue when the node is brought back online depending on whether the underlying datastore has synchronous or asynchronous writes.

Deprecated: use github.com/ipfs/boxo/provider/queue.Queue

func NewQueue deprecated

func NewQueue(ctx context.Context, name string, ds datastore.Datastore) (*Queue, error)

NewQueue creates a queue for cids

Deprecated: use github.com/ipfs/boxo/provider/queue.NewQueue

func (*Queue) Close

func (q *Queue) Close() error

Close stops the queue

func (*Queue) Dequeue

func (q *Queue) Dequeue() <-chan cid.Cid

Dequeue returns a channel that if listened to will remove entries from the queue

func (*Queue) Enqueue

func (q *Queue) Enqueue(cid cid.Cid) error

Enqueue puts a cid in the queue

Jump to

Keyboard shortcuts

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