![]() |
#include <aerospike/as_atomic.h>
#include <aerospike/as_config.h>
#include <aerospike/as_conn_pool.h>
#include <aerospike/as_error.h>
#include <aerospike/as_event.h>
#include <aerospike/as_latency.h>
#include <aerospike/as_socket.h>
#include <aerospike/as_partition.h>
#include <aerospike/as_queue.h>
#include <aerospike/as_vector.h>
#include <netinet/in.h>
#include <sys/uio.h>
Go to the source code of this file.
Data Structures | |
struct | as_address |
struct | as_async_conn_pool |
struct | as_node |
struct | as_node_info |
struct | as_node_metrics |
struct | as_rack |
struct | as_racks |
struct | as_session |
Macros | |
#define | AS_ADDRESS4_MAX 4 |
#define | AS_ADDRESS6_MAX 8 |
#define | AS_FEATURES_BATCH_ANY (1 << 2) |
#define | AS_FEATURES_PARTITION_QUERY (1 << 3) |
#define | AS_FEATURES_PARTITION_SCAN (1 << 0) |
#define | AS_FEATURES_QUERY_SHOW (1 << 1) |
#define | AS_HOSTNAME_SIZE 256 |
#define | AS_NODE_NAME_MAX_SIZE AS_NODE_NAME_SIZE |
#define | AS_NODE_NAME_SIZE 20 |
#define AS_HOSTNAME_SIZE 256 |
#define AS_NODE_NAME_MAX_SIZE AS_NODE_NAME_SIZE |
Are hosts equal.
Definition at line 625 of file as_node.h.
References as_host::name, and as_host::port.
|
private |
Add socket address to node addresses.
|
inlinestatic |
Increment command error count. If the error is retryable, multiple errors per command may occur.
Definition at line 685 of file as_node.h.
References as_incr_uint64, and as_node::error_count.
|
private |
Record latency of type latency_type for node
|
inlinestatic |
Increment command timeout count. If the timeout is retryable (ie socketTimeout), multiple timeouts per command may occur.
Definition at line 704 of file as_node.h.
References as_incr_uint64, and as_node::timeout_count.
|
private |
Attempt to authenticate given current cluster's user and password.
|
private |
Balance sync connections.
|
inlinestaticprivate |
Close a node's connection and update node/pool statistics.
Definition at line 576 of file as_node.h.
References as_conn_pool_decr(), as_incr_uint32, as_socket_close(), and as_node::sync_conns_closed.
Close a node's connection and update node statistics.
Definition at line 588 of file as_node.h.
References as_incr_uint32, as_socket_close(), and as_node::sync_conns_closed.
|
private |
Create new cluster node.
|
private |
Create configured minimum number of connections.
|
inlinestaticprivate |
Set node to inactive.
Definition at line 469 of file as_node.h.
References as_node::active, and as_store_uint8_rls.
Close all connections in pool and free resources.
|
private |
Destroy node metrics.
|
private |
Enable metrics at the node level
|
inlinestatic |
Get primary socket address.
Definition at line 543 of file as_node.h.
References as_node::address_index, and as_node::addresses.
|
inlinestatic |
Get socket address as a string.
Definition at line 552 of file as_node.h.
References as_node::address_index, as_node::addresses, and as_address::name.
|
private |
Get a connection to the given node from pool and validate. Return 0 on success.
|
inlinestatic |
Return command error count. The value is cumulative and not reset per metrics interval.
Definition at line 675 of file as_node.h.
References as_load_uint64, and as_node::error_count.
|
inlinestatic |
Return command timeout count. The value is cumulative and not reset per metrics interval.
Definition at line 694 of file as_node.h.
References as_load_uint64, and as_node::timeout_count.
|
private |
Does node contain rack.
|
inlinestaticprivate |
Destroy node_info contents.
Definition at line 635 of file as_node.h.
References as_socket_close(), as_node_info::session, and as_node_info::socket.
|
inlinestaticprivate |
Check if node is active from a command thread.
Definition at line 459 of file as_node.h.
References as_node::active, and as_load_uint8_acq.
Put connection back into pool.
Definition at line 599 of file as_node.h.
References as_conn_pool_push_head(), as_node_close_connection(), as_socket::last_used, and as_socket::pool.
|
inlinestaticprivate |
Release existing cluster node.
Definition at line 510 of file as_node.h.
References as_aaf_uint32_rls, as_fence_acq, as_node_destroy(), and as_node::ref_count.
|
private |
Release node on next cluster tend iteration.
|
inlinestaticprivate |
Reserve existing cluster node.
Definition at line 490 of file as_node.h.
References as_incr_uint32, and as_node::ref_count.
|
private |
Set hostname.
|
private |
Tell tend thread to perform another node login.
|
inlinestaticprivate |
|
inlinestaticprivate |
Release existing session.
Definition at line 724 of file as_node.h.
References as_aaf_uint32_rls, and as_session::ref_count.