Open connections stat appears to only count for one thread
Closed this issue · 2 comments
With my current set up, it seems like the open connections stat (calculated as socket_create_count - socket_close_count) is only reflecting the open connections for a single thread. For example, with 3 threads and 50 connections per thread, I am seeing in the rpc perf logs:
2018-08-01 21:07:36.410 INFO [rpc-perf] Config: Threads: 3 Poolsize: 50
...
2018-08-01 21:09:37.449 INFO [rpc-perf] Window: 1
2018-08-01 21:09:37.449 INFO [rpc-perf] Connections: Ok: 0 Error: 0 Timeout: 0 Open: 50
I am seeing on my server that all of the expected connections are there. So it would appear that rpc perf is creating all of the connections it is configured with, but the stat is counting them incorrectly. For reference, here is the config file I am using:
[general]
threads = 3
connections = 50
windows = 60
duration = 60
request-timeout = 200
connect-timeout = 500
[[workload]]
name = "get_counter"
method = "get"
rate = 800
[[workload.parameter]]
style = "random"
size = 25
num = 100000000
regenerate = true
[[workload]]
name = "get_tweet"
method = "get"
rate = 800
[[workload.parameter]]
style = "random"
size = 24
num = 40000000
regenerate = true
[[workload]]
name = "set_counter"
method = "set"
rate = 100
[[workload.parameter]]
style = "random"
size = 25
num = 100000000
regenerate = true
[[workload.parameter]]
style = "random"
size = 8
num = 10
regenerate = false
[[workload]]
name = "set_tweet"
method = "set"
rate = 100
[[workload.parameter]]
style = "random"
size = 24
num = 40000000
regenerate = true
[[workload.parameter]]
style = "random"
size = 1024
num = 10
regenerate = false
Forgot to mention, I tried this with different thread counts and saw the same thing; with 4 threads, there were 200 connections from rpc perf, but the stat was still 50.
This should be working properly with the new code in master. If you find any stats issues on the new codebase, please open a new issue.