queue

package
v1.0.33 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2024 License: Apache-2.0 Imports: 4 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 struct {
	sync.Mutex
	*QueueConfig
	*time.Ticker
	// contains filtered or unexported fields
}

func NewQueue

func NewQueue(c *QueueConfig) *Queue

func (*Queue) Flush

func (q *Queue) Flush() error

func (*Queue) Push

func (q *Queue) Push(values []interface{})

func (*Queue) Run

func (q *Queue) Run()

func (*Queue) Stop

func (q *Queue) Stop() error

type QueueConfig added in v1.0.21

type QueueConfig struct {
	*sqlx.DB
	FlushInterval time.Duration
	FlushCount    int
	Sql           string
}

Jump to

Keyboard shortcuts

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