This commit is contained in:
crusader 2017-10-13 14:32:56 +09:00
parent 5826f0117a
commit fb71acaaa5
2 changed files with 3 additions and 3 deletions

View File

@ -26,7 +26,7 @@ type probeServlet struct {
func (s *probeServlet) IsCanConnect(ctx *fasthttp.RequestCtx) bool {
var buf []byte
if buf = ctx.Request.Header.Peek(ProbeHeader_ProbeKey); nil != buf {
if buf = ctx.Request.Header.Peek(ProbeHeader_ProbeKey); nil == buf {
return false
}
probeKey := string(buf)

View File

@ -9,8 +9,8 @@ import (
func Subscribe(ctx context.Context, redisConn redis.Conn) {
s := ofs_redis.New(ctx, redisConn)
probeS := newProbeSubscriberHandler(ctx, "probe")
authS := newAuthSubscriberHandler(ctx, "auth")
probeS := newProbeSubscriberHandler(ctx, "/probe")
authS := newAuthSubscriberHandler(ctx, "/auth")
s.Subscribe(probeS)
s.Subscribe(authS)