cube
cube copied to clipboard
Add redisPool `numTestsPerEvictionRun` option
Is your feature request related to a problem? Please describe.
redisPool use node-pool npm package. default numTestsPerEvictionRun=3 maybe too small if we have many requests
with numTestsPerEvictionRun option we can control how fast redis connections will be released. if posible i can make pr
some links
https://github.com/coopernurse/node-pool
@rongfengliang Yeah. Makes sense to make it ~200-300. Need to test it thoroughly though. cc @ovr
Yeah, it's a good idea, but there are some things, that should be done to fix stability of the RedisPool:
numTestsPerEvictionRun- I think we should use
maxWaitingClientsto protect an unexpected case when there are promises that are waiting for a free connection. Probably, it should max * 3 - Finish with release https://github.com/cube-js/cube.js/pull/2575
- test connection after releasing.
👋 a quick reminder that we will be replacing Redis with Cube Store as announced in this blog post.
I believe that this issue is not relevant anymore since Cube Store has replaced Redis for query queue and cache management.
Docs: https://cube.dev/docs/product/deployment#redis
Announcement: https://cube.dev/blog/how-you-win-by-using-cube-store-part-1