server

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2021 License: MIT Imports: 17 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ClientHandler

func ClientHandler(conn net.Conn, app *App)

Types

type App

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

func NewApp

func NewApp(conf *config.Config) *App

initialize an app

func (*App) Close

func (app *App) Close() error

func (*App) GetTidis

func (app *App) GetTidis() *tidis.Tidis

func (*App) Run

func (app *App) Run()

type Client

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

func (*Client) CommitTxn

func (c *Client) CommitTxn() error

func (*Client) DBID added in v1.0.0

func (c *Client) DBID() uint8

func (*Client) FlushResp

func (c *Client) FlushResp(resp interface{}) error

func (*Client) GetCurrentTxn

func (c *Client) GetCurrentTxn() kv.Transaction

func (*Client) IsTxn

func (c *Client) IsTxn() bool

func (*Client) NewTxn

func (c *Client) NewTxn() error

for multi transaction commands

func (*Client) Resp

func (c *Client) Resp(resp interface{}) error

func (*Client) Resp1

func (c *Client) Resp1(resp interface{}) error

treat string as bulk array

func (*Client) RollbackTxn

func (c *Client) RollbackTxn() error

func (*Client) SelectDB added in v1.0.0

func (c *Client) SelectDB(dbId uint8)

type CmdFunc

type CmdFunc func(c *Client) error

type Command

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

Jump to

Keyboard shortcuts

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