Class: Aerospike::QueryPartitionCommand

Inherits:
QueryCommand show all
Defined in:
lib/aerospike/query/query_partition_command.rb

Overview

:nodoc:

Instance Method Summary collapse

Methods inherited from QueryCommand

#is_scan?

Methods inherited from StreamCommand

#parse_group

Methods inherited from MultiCommand

#compressed?, #get_node, #parse_group, #parse_key, #parse_record, #parse_result, #read_bytes, #skip_key, #stop, #valid?

Methods inherited from Command

#execute, #set_delete, #set_exists, #set_operate, #set_query, #set_read, #set_read_for_key_only, #set_read_header, #set_scan, #set_touch, #set_udf, #set_write, #write_bins

Constructor Details

#initialize(cluster, node, tracker, policy, statement, recordset, node_partitions) ⇒ QueryPartitionCommand

Returns a new instance of QueryPartitionCommand.



24
25
26
27
28
# File 'lib/aerospike/query/query_partition_command.rb', line 24

def initialize(cluster, node, tracker, policy, statement, recordset, node_partitions)
  super(cluster, node, policy, statement, recordset, @node_partitions)
  @node_partitions = node_partitions
  @tracker = tracker
end

Instance Method Details

#should_retry(e) ⇒ Object



36
37
38
39
# File 'lib/aerospike/query/query_partition_command.rb', line 36

def should_retry(e)
  # !! converts nil to false
  !!@tracker&.should_retry(@node_partitions, e)
end

#write_bufferObject



30
31
32
# File 'lib/aerospike/query/query_partition_command.rb', line 30

def write_buffer
  set_query(@cluster, @policy, @statement, false, @node_partitions)
end