Documentation ¶
Index ¶
- Constants
- type Liteq
- func (l *Liteq) Commit(recipts []*gq.Receipt) error
- func (l *Liteq) ConsumeBatch(size int) ([]*gq.ConsumerMessage, error)
- func (l *Liteq) Create() error
- func (l *Liteq) Destroy() error
- func (l *Liteq) Exit() bool
- func (l *Liteq) Publish(messages []*gq.Message) error
- func (l *Liteq) StopConsumer()
- func (l *Liteq) Stream(size int, messages chan []*gq.ConsumerMessage, pause time.Duration)
Constants ¶
View Source
const TimeWithMsSqlite = "STRFTIME('%Y-%m-%d %H:%M:%f', 'NOW')"
TimeWithMsSqlite ... Special constant to get a time with milliseconds. This is helpful for checkout as the timeout might be sub second
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Liteq ¶
type Liteq struct { DB *sql.DB Prefix string TTL time.Duration // contains filtered or unexported fields }
Liteq Structure for sqlite
func (*Liteq) ConsumeBatch ¶
func (l *Liteq) ConsumeBatch(size int) ([]*gq.ConsumerMessage, error)
ConsumeBatch ... This consumes a number of messages up to the limit
func (*Liteq) StopConsumer ¶
func (l *Liteq) StopConsumer()
StopConsumer ... Stop consuming messages
Click to show internal directories.
Click to hide internal directories.