365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
|
# File 'lib/aerospike/command/admin_command.rb', line 365
def read_users(cluster, policy)
write_size
node = cluster.random_node
timeout = 1
timeout = policy.timeout if policy != nil && policy.timeout > 0
status = -1
list = []
begin
conn = node.get_connection(timeout)
conn.write(@data_buffer, @data_offset)
status, list = read_user_blocks(conn)
node.put_connection(conn)
rescue => e
conn.close if conn
raise e
end
raise Exceptions::Aerospike.new(status) if status > 0
return list
end
|