From 1ab40b99b8b984a19bbb2bafd8bf88822831ee20 Mon Sep 17 00:00:00 2001 From: Minh Nguyen Date: Fri, 25 Mar 2022 14:35:44 +0700 Subject: [PATCH] log-test --- get_with_prefix_pattern.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/get_with_prefix_pattern.go b/get_with_prefix_pattern.go index 11b03b6..628ca9c 100644 --- a/get_with_prefix_pattern.go +++ b/get_with_prefix_pattern.go @@ -1,6 +1,9 @@ package redisdb -import "context" +import ( + "context" + "fmt" +) // GetWithPrefixPattern ... func GetWithPrefixPattern(pattern string, limit int64) (keys []string, values []string) { @@ -16,10 +19,12 @@ func GetWithPrefixPattern(pattern string, limit int64) (keys []string, values [] keys, cursor, err = rdb.Scan(ctx, cursor, pattern, limit).Result() if err != nil { + fmt.Println("err redis scan: ", err.Error()) return } if len(keys) == 0 { + fmt.Println("NO keys") return }