Class: Algolia::ChunkedHelperOptions

Inherits:
Object
  • Object
show all
Defined in:
lib/algolia/chunked_helper_options.rb

Overview

Optional configuration for chunked helpers that batch records and poll for task completion.

Constant Summary collapse

DEFAULT_MAX_RETRIES =
100

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(max_retries: DEFAULT_MAX_RETRIES) ⇒ ChunkedHelperOptions

Returns a new instance of ChunkedHelperOptions.



7
8
9
# File 'lib/algolia/chunked_helper_options.rb', line 7

def initialize(max_retries: DEFAULT_MAX_RETRIES)
  @max_retries = max_retries
end

Instance Attribute Details

#max_retriesObject (readonly)

Returns the value of attribute max_retries.



5
6
7
# File 'lib/algolia/chunked_helper_options.rb', line 5

def max_retries
  @max_retries
end

Class Method Details

.resolve(options) ⇒ Object



11
12
13
# File 'lib/algolia/chunked_helper_options.rb', line 11

def self.resolve(options)
  options || new
end