MCPcopy
hub / github.com/CodisLabs/codis / Mgrt

Method Mgrt

extern/deprecated/redis-test/utils.go:264–279  ·  view source on GitHub ↗
(c, dst *Conn, exists bool)

Source from the content-addressed store, hash-verified

262}
263
264func (u *Unit) Mgrt(c, dst *Conn, exists bool) {
265 var rsp interface{}
266 defer func() {
267 if x := recover(); x != nil {
268 Panic("slotsmgrtone: c = %s, key = '%s', dst = %s, error = '%s', rsp = %v", c.Addr(), u.key, dst.Addr(), x, rsp)
269 }
270 }()
271 var err error
272 if rsp, err = c.Do("slotsmgrtone", dst.Host, dst.Port, Timeout, u.key); err != nil {
273 panic(err)
274 }
275 v := c.Int(rsp)
276 if exists && v != 1 {
277 panic("not exists")
278 }
279}
280
281func (u *Unit) MgrtTag(c, dst *Conn, exists bool) {
282 var rsp interface{}

Callers 1

mainMethod · 0.95

Calls 4

PanicFunction · 0.70
AddrMethod · 0.45
DoMethod · 0.45
IntMethod · 0.45

Tested by

no test coverage detected