Documentation
¶
Index ¶
- Variables
- type Message
- type RedisBroker
- func (r *RedisBroker) Ack(queue string, msg *Message) error
- func (r *RedisBroker) Cancel(queue string, Jid string) error
- func (r *RedisBroker) GetCancel(queue string) (string, error)
- func (r *RedisBroker) Next(ctx context.Context, queue string) (msg *Message, err error)
- func (r *RedisBroker) Send(queue string, msg *Message) error
- type RedisClient
- func (r *RedisClient) CancelPop(ctx context.Context, prefix string) (string, error)
- func (r *RedisClient) LPush(ctx context.Context, prefix string, values ...interface{}) error
- func (r *RedisClient) LRem(ctx context.Context, prefix string, count int64, value interface{}) error
- func (r *RedisClient) Push(ctx context.Context, prefix string, values ...interface{}) error
- func (r *RedisClient) RPopLPush(ctx context.Context, prefix string) (string, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrEmptyQueue = errors.New("empty queue")
Functions ¶
This section is empty.
Types ¶
type RedisBroker ¶
type RedisBroker struct {
// contains filtered or unexported fields
}
func NewRedisBroker ¶
func NewRedisBroker(host, port, password string) (*RedisBroker, error)
type RedisClient ¶
type RedisClient struct { WaitQueue string WorkQueue string CancelQueue string // contains filtered or unexported fields }
func NewRedisClient ¶
func NewRedisClient(host, port, password string) (*RedisClient, error)
func (*RedisClient) LPush ¶
func (r *RedisClient) LPush(ctx context.Context, prefix string, values ...interface{}) error
Click to show internal directories.
Click to hide internal directories.