lua parser and redis2 questions

gregr401 nginx-forum at
Mon Jun 6 02:40:29 MSD 2011

Thanks, logar.  I mimicked your test config and the below is the

location /testluaparser {
		content_by_lua '
		     local replies = ngx.location.capture("/redis2")
		     local parser = require("redis.parser")
		     ngx.say("reply status is:",replies.status)
		     ngx.say("reply body is:",replies.body)
		     ngx.say("end of showresults")
		     local res,typ = parser.parse_reply(replies.body)
		     ngx.say("type=", typ)
		     ngx.say("res=", res)

reply status is:200
reply body is:$11
auth is off

end of showresults
res=auth is off

I'm still stuck with properly parsing pipelined requests as I'm
attempting to perform an AUTH check in conjunction with a few gets.

Posted at Nginx Forum:,203154,204202#msg-204202

More information about the nginx mailing list