Aerospike-go-cilent: High latency and Connections stuck in CLOSE_WAIT

Viewed 201

I am trying to run a server written in Golang which internally calls aerospike client.

Initially after server start latencies measured from the client side of aerospike were under control but after some time latencies are getting high and not coming down.

Based on my observation during high latencies, many connections from aerospike client to aerospike server are in close_wait state

I am using default parameters for client policy i.e, ConnectionQueueSize = 256 and LimitConnectionsToQueueSize = true

My guess is since many connections are in close_wait state and we are limiting connections it is waiting for connection to close and create a new one and because of that latencies are high

If that is correct, How can we close the connections faster that are in the close_wait state? Otherwise, What can be the reason for this?

P.S,

  1. We measured latency from aerospike server side it was under 1ms (As expected)
  2. No Network congestion from aerospike server side as well as aerospike client side
1 Answers
Related