Redis let us to select a specific section of information. But still it can make a lot of data, when you only need to know the value of a property in a section.
The proposed syntax:
INFO [section][property ...]
examples: INFO clients INFO clients connected_clients INFO clients connected_clients maxclients
pros: - mainly avoid a long response from the server - secondly, it is easier for the client to parse the response
cons: it is probably a little added cpu time for Redis to filter the response.
Comment From: sundb
Maybe this will also meet your needs:
redis-cli info clients | grep -E "connected_clients|maxclients"
Comment From: githubfr
Thank you sundb,
Yes, i use this too and it is usefull, but unfortunately this is for a project where i don't have access to grep, and i had to iterate in an array to compare the keys. This feature request aims to make a generic method. It is always possible to parse the data and extract the items, whatever is the method (with grep, regex, or whatever else as i did) but i found it could be a candidate for a feature request however.
Comment From: oranagra
I must say I don't like that feature too much. I imagine the implementation on Redis's side to support this will be complicated and induce overheads for normal use cases. Also, it seems to me that it's not very useful for the vast majority of users.
Comment From: githubfr
Hello, thank you for your response,
Now that you confirm it will be complicated and induce overheads, i agree to conclude it is not a very good idea then.
I don't know how Redis is used in terms of project typology, but sometime the clients have a poor ability to do these small tasks, but i agree it's not a big deal either.
So, in my side, this feature is closed.