We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 623a3bc commit a26d7ebCopy full SHA for a26d7eb
exporter/info.go
@@ -249,7 +249,7 @@ func parseDBKeyspaceString(inputKey string, inputVal string) (keysTotal float64,
249
}
250
251
split := strings.Split(inputVal, ",")
252
- if len(split) < 2 || len(split) > 4 {
+ if len(split) < 2 {
253
log.Debugf("parseDBKeyspaceString strings.Split(inputVal) invalid: %#v", split)
254
return
255
exporter/info_test.go
@@ -31,7 +31,7 @@ func TestKeyspaceStringParser(t *testing.T) {
31
{db: "db3", stats: "keys=123,expires=0,avg_ttl=zzz", ok: false},
32
{db: "db3", stats: "keys=1,expires=0,avg_ttl=zzz,cached_keys=0", ok: false},
33
{db: "db3", stats: "keys=1,expires=0,avg_ttl=0,cached_keys=zzz", ok: false},
34
- {db: "db3", stats: "keys=1,expires=0,avg_ttl=0,cached_keys=0,extra=0", ok: false},
+ {db: "db3", stats: "keys=1,expires=0,avg_ttl=0,cached_keys=0,extra=0", keysTotal: 1, keysEx: 0, avgTTL: 0, keysCached: 0, ok: true},
35
36
{db: "db0", stats: "keys=1,expires=0,avg_ttl=0", keysTotal: 1, keysEx: 0, avgTTL: 0, keysCached: -1, ok: true},
37
{db: "db0", stats: "keys=1,expires=0,avg_ttl=0,cached_keys=0", keysTotal: 1, keysEx: 0, avgTTL: 0, keysCached: 0, ok: true},
0 commit comments