redose

package module
v0.0.0-...-b39d66c Latest Latest
Warning

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

Go to latest
Published: Feb 22, 2022 License: MIT Imports: 13 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

redose

Redis Protocol Gateway

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalidCredentials = errors.New("invalid credentials")

Functions

This section is empty.

Types

type Auth

type Auth struct {
	DB *sql.DB
	// contains filtered or unexported fields
}

Auth use sql database for retrieve user

func (*Auth) Validate

func (a *Auth) Validate(user, password string) error

type Server

type Server struct {
	Addr        string
	TLSConfig   *tls.Config
	EnableAuth  bool
	AuthService *Auth
	RedisClient *redis.Client
	// contains filtered or unexported fields
}

Server is the redose server

func (*Server) Auth

func (h *Server) Auth(conn redcon.Conn, cmd redcon.Command)

func (*Server) DBSize

func (h *Server) DBSize(conn redcon.Conn, cmd redcon.Command)

func (*Server) Del

func (h *Server) Del(conn redcon.Conn, cmd redcon.Command)

func (*Server) Expire

func (h *Server) Expire(conn redcon.Conn, cmd redcon.Command)

func (*Server) Get

func (h *Server) Get(conn redcon.Conn, cmd redcon.Command)

func (*Server) Info

func (h *Server) Info(conn redcon.Conn, cmd redcon.Command)

func (*Server) ListenAndServe

func (h *Server) ListenAndServe() error

func (*Server) ListenAndServeTLS

func (h *Server) ListenAndServeTLS(certFile, keyFile string) error

func (*Server) MGet

func (h *Server) MGet(conn redcon.Conn, cmd redcon.Command)

func (*Server) PExpire

func (h *Server) PExpire(conn redcon.Conn, cmd redcon.Command)

func (*Server) PTTL

func (h *Server) PTTL(conn redcon.Conn, cmd redcon.Command)

func (*Server) Ping

func (h *Server) Ping(conn redcon.Conn, cmd redcon.Command)

func (*Server) Quit

func (h *Server) Quit(conn redcon.Conn, cmd redcon.Command)

func (*Server) Scan

func (h *Server) Scan(conn redcon.Conn, cmd redcon.Command)

func (*Server) Select

func (h *Server) Select(conn redcon.Conn, cmd redcon.Command)

func (*Server) Set

func (h *Server) Set(conn redcon.Conn, cmd redcon.Command)

func (*Server) SetEX

func (h *Server) SetEX(conn redcon.Conn, cmd redcon.Command)

func (*Server) SetNX

func (h *Server) SetNX(conn redcon.Conn, cmd redcon.Command)

func (*Server) TTL

func (h *Server) TTL(conn redcon.Conn, cmd redcon.Command)

func (*Server) Type

func (h *Server) Type(conn redcon.Conn, cmd redcon.Command)

Directories

Path Synopsis
cmd
redose command

Jump to

Keyboard shortcuts

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