This feature permit to configure directly from the configuration file which kind of metrics you want to grab and which kind of metrics it is (gauge, counter...)
New captured data: - used_memory_peak: it's nice to know what is the max held and when it has reach it - instantaneous_ops_per_sec: several operations can be performed (bulk included), it's good to know it - rdb_bgsave_in_progress: to know how many time a bgsave can occur in a day and how long
Chose 'derive' type since the recent change in hits/misses is more interesting than the total. These metrics were added to Redis's INFO command in Oct 2010, so they've been there quite a while. Still we check to make sure they exist in case user has an old version of redis. See commit in Redis: antirez/redis@53eeeaf
While testing on a Redis 2.4.10 server, I got "redis_info plugin: Bad format for info line:" because Redis sends an extra blank line at the end of the output from the INFO command. This patch ignores blank lines returned from the Redis server.