Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConsumeOption ¶
type ConsumeOption func(options *consumeOptions)
func WithConsumeName ¶
func WithConsumeName(name string) ConsumeOption
func WithReadCount ¶
func WithReadCount(count int64) ConsumeOption
func WithReconnectSec ¶
func WithReconnectSec(timeSec int32) ConsumeOption
type ProduceOption ¶
type ProduceOption func(options *produceOptions)
func WithDefaultKey ¶
func WithDefaultKey(key string) ProduceOption
type RedisPubSub ¶
type RedisPubSub struct {
// contains filtered or unexported fields
}
func NewRedisPubSub ¶
func NewRedisPubSub(cli *redis.Client) *RedisPubSub
type RedisStream ¶
type RedisStream struct {
// contains filtered or unexported fields
}
func NewRedisStream ¶
func NewRedisStream(cli *redis.Client) *RedisStream
func (*RedisStream) Consume ¶
func (r *RedisStream) Consume(ctx context.Context, stream, group string, fn consumeFunc, opts ...ConsumeOption) error
func (*RedisStream) Produce ¶
func (r *RedisStream) Produce(ctx context.Context, stream string, msg interface{}, opts ...ProduceOption) error
Click to show internal directories.
Click to hide internal directories.