pubsub

package
v0.0.0-...-db24ddd Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2023 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 Pubsub

type Pubsub interface {
	Publish(channel string, payload string) error
	Subscribe(channel string) *redis.PubSub
	Get(key string) *redis.StringCmd
	Del(key string) *redis.IntCmd
	Set(key string, value []byte) *redis.StatusCmd
	Close() error
}

func GetPubsub

func GetPubsub(connStr string) Pubsub

type RedisPubsub

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

func GetRedisPubsub

func GetRedisPubsub(connStr string) *RedisPubsub

func (*RedisPubsub) Close

func (rp *RedisPubsub) Close() error

func (*RedisPubsub) Del

func (rp *RedisPubsub) Del(key string) *redis.IntCmd

func (*RedisPubsub) Get

func (rp *RedisPubsub) Get(key string) *redis.StringCmd

func (*RedisPubsub) Publish

func (rp *RedisPubsub) Publish(channel string, payload string) error

func (*RedisPubsub) Set

func (rp *RedisPubsub) Set(key string, value []byte) *redis.StatusCmd

func (*RedisPubsub) Subscribe

func (rp *RedisPubsub) Subscribe(channel string) *redis.PubSub

Jump to

Keyboard shortcuts

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