joeferner / redis-commander

Redis management tool written in node.js
http://joeferner.github.io/redis-commander/
MIT License
3.56k stars 460 forks source link

Adding Type Filter to initial SCAN #521

Open koromkorom opened 1 year ago

koromkorom commented 1 year ago

Hi,

I just wanted to suggest to add the TYPE filter as a feature in redis commander for the initial SCAN (in case USE_SCAN is set) in addition to MATCH (which uses ROOT_PATTERN).

For me this would be really nice, because I am having 100k similar string keys, but I am actually mostly interested in just 5 lists or so. If there was a negative filter (or regex) for MATCH, I could use that, but unfortunately that's not possible. The 100k strings cause a lot of load locally for some reason.

In case adding the TYPE parameter is something you would be interested in, I could also do a PR. Maybe call it ROOT_TYPE?

sseide commented 1 year ago

Hi - sorry for late response.

Yes this sound usefull and a PR is welcome. "ioredis" seems to support it (https://redis.github.io/ioredis/classes/Redis.html#scan) therefore should be possible.