Redis管道与事务原理及Lua脚本应用.pdfVIP

  • 1
  • 0
  • 约8.75千字
  • 约 8页
  • 2026-09-08 发布于北京
  • 举报

零声教育

Mark

老师

Redis

管道

Redis

pipeline

是由客户端的,而不是由服务端的;

type

Conn

interface

{

1

//

关闭连接。

2

Close()

error

3

4

//

当连接不可用时返回非空值。

5

Err()

error

6

7

//

Do

向服务器发送命令并返回接收到的回复。

8

Do(commanme

string,

args

...

interface{})

(reply

interface{},

err

9

error)

10

//

Do

=发送

+刷新

+接收

11

12

//

Send

将命令写入客

户端的输出缓冲区。

13

Send(commanme

string,

args

...interface{})

error

14

15

//

Flush

刷新输出

缓冲区到

Redis

服务器。

16

Flush()

error

17

18

//

Receive

Redis

服务器接收单个回复

19

Receive()

(reply

interface{},

err

error)

20

}21

零声教育Mark老师

文档评论(0)

1亿VIP精品文档

相关文档