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
Is there a way to retrieve the current cluster status (number of nodes connected, and any other data about the current state) ? The info command goes to the server and isn't quite what I'm looking for. Just the current state of the client connections. I'd love to be able to see if some (or all) AS instances become unavailable to the client library in order to proactively deal with that without relying on having to make a call just to see if an error is thrown.
Something similar to node_redis client.connected
Quickly browsing the source there doesn't seem to be any way to handle this.
Less important but also it would be nice if it was possible to have an ability to listen for lifecycle events in connections to Aerospike (again comparing with node_redis, something like the events: error, reconnecting, end etc).
Maybe getting the current status without making an actual call to the Aerospike server is possible already but I missed it.
The text was updated successfully, but these errors were encountered:
At the moment there is unfortunately no way to get information about the cluster status from the Aerospike Node.js client without sending a request to one or more of the cluster's nodes. The C client library, which the Node.js client uses internally, does support a aerospike_cluster_is_connected method, but it's not exposed in the JS interface of the client.
I will be adding an isConnected method to the Client interface in the upcoming v2 release. This method checks the health of the client connections and will return false if none of the server connections are currently alive.
Is there a way to retrieve the current cluster status (number of nodes connected, and any other data about the current state) ? The info command goes to the server and isn't quite what I'm looking for. Just the current state of the client connections. I'd love to be able to see if some (or all) AS instances become unavailable to the client library in order to proactively deal with that without relying on having to make a call just to see if an error is thrown.
Something similar to node_redis
client.connected
Quickly browsing the source there doesn't seem to be any way to handle this.
Less important but also it would be nice if it was possible to have an ability to listen for lifecycle events in connections to Aerospike (again comparing with node_redis, something like the events:
error
,reconnecting
,end
etc).Maybe getting the current status without making an actual call to the Aerospike server is possible already but I missed it.
The text was updated successfully, but these errors were encountered: