You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
resp:=flag.String("resp", "", "redis command response protocol (2 - RESP 2, 3 - RESP 3). If empty will not enforce it.")
156
+
nameserver:=flag.String("nameserver", "", "the IP address of the DNS name server. The IP address can be an IPv4 or an IPv6 address. If empty will use the default host namserver.")
156
157
flag.Var(&benchmarkCommands, "cmd", "Specify a query to send in quotes. Each command that you specify is run with its ratio. For example:-cmd=\"SET __key__ __value__\" -cmd-ratio=1")
157
158
flag.Var(&benchmarkCommandsRatios, "cmd-ratio", "The query ratio vs other queries used in the same benchmark. Each command that you specify is run with its ratio. For example: -cmd=\"SET __key__ __value__\" -cmd-ratio=0.8 -cmd=\"GET __key__\" -cmd-ratio=0.2")
158
159
@@ -220,7 +221,27 @@ func main() {
220
221
} elseif*resp=="3" {
221
222
opts.Protocol="3"
222
223
}
223
-
ips, _:=net.LookupIP(*host)
224
+
225
+
ips:=make([]net.IP, 0)
226
+
if*nameserver!="" {
227
+
fmt.Printf("Using %s to resolve hostname %s\n", *nameserver, *host)
0 commit comments