Closed moshufenmo closed 5 years ago
You don't need to close the connection, client is based on lua-resty-redis and will set keep-alive by itself
close as of now.
You don't need to close the connection, client is based on lua-resty-redis and will set keep-alive by itself
You said this client is based on lua-resty-redis, I don't need to close the connection manually, but lua-resty-redis has method named close/keep-lived, it's also a good hobbit to close the connection in time, right? if I don't close the connection in time, it will be closed during GC. Is that will impact the performance? or something else?
Set keep-alive itself means client has already done this job for you.(Different with lua-resty-redis) If you look at the source code of rediscluster.lua, both handleCommandWithRetry() and commit_pipeline() has already set keep alive timeout. You can configure while you init client as per guide.
Thanks for your code, we need it in deep.
after execute the command, do I need to close the connection manually? like keep-alived or close ? how to call these methods ? can u show some examples ?
Thanks.