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
As I was verifying how a connection failure is experienced, I found the following about connections:
Client waits for 4-5s for each host to connect;
On failure, it tries the next ones, serially;
It blocks event loop (no await)
connTimeoutMs doesn't seem to work
Can this experience be improved?
Sample program and output:
importAerospikefrom"aerospike";conststart=Date.now();constclient=Aerospike.client({"connTimeoutMs": 500,"hosts": "aerospike,aerospike2",});client.connect().finally(()=>{client.close();});console.log(`Connection took ${Date.now()-start}ms`);
node@1f3bf2734242:/app$ node connect.mjs
Jul 13 2023 17:22:54 GMT: WARN (9170) [as_pipe.c:208] [read_file] - Failed to open /proc/sys/net/core/wmem_max for reading
Jul 13 2023 17:22:54 GMT: WARN (9170) [as_pipe.c:267] [get_buffer_size] - Failed to read /proc/sys/net/core/wmem_max; should be at least 5242880. Please verify.
Jul 13 2023 17:22:54 GMT: WARN (9170) [as_pipe.c:208] [read_file] - Failed to open /proc/sys/net/core/rmem_max for reading
Jul 13 2023 17:22:54 GMT: WARN (9170) [as_pipe.c:267] [get_buffer_size] - Failed to read /proc/sys/net/core/rmem_max; should be at least 15728640. Please verify.
Jul 13 2023 17:22:58 GMT: WARN (9170) [as_cluster.c:281] [as_cluster_seed_node] - Failed to lookup aerospike1 3000. AEROSPIKE_ERR_INVALID_HOST Invalid hostname aerospike: Name or service not known
Jul 13 2023 17:23:02 GMT: WARN (9170) [as_cluster.c:281] [as_cluster_seed_node] - Failed to lookup aerospike2 3000. AEROSPIKE_ERR_INVALID_HOST Invalid hostname aerospike2: Name or service not known
Jul 13 2023 17:23:02 GMT: ERROR(9170) [command.cc:84] [ErrorCallback] - Client error in Connect command: Failed to connect [-1]
Connection took 7943 ms
As I was verifying how a connection failure is experienced, I found the following about connections:
connTimeoutMs
doesn't seem to workCan this experience be improved?
Sample program and output:
node:18 container
aerospike client v5.6.0
runtime AWS Lambda
The text was updated successfully, but these errors were encountered: