Class: Temporalio::Worker::Tuner::SlotSupplier::ResourceBased

Inherits:
Temporalio::Worker::Tuner::SlotSupplier show all
Defined in:
lib/temporalio/worker/tuner.rb

Overview

Note:

WARNING: This API is experimental.

A slot supplier that will dynamically adjust the number of slots based on resource usage.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(tuner_options:, slot_options:) ⇒ ResourceBased

Create a reosurce-based slot supplier.

Parameters:



33
34
35
36
# File 'lib/temporalio/worker/tuner.rb', line 33

def initialize(tuner_options:, slot_options:) # rubocop:disable Lint/MissingSuper
  @tuner_options = tuner_options
  @slot_options = slot_options
end

Instance Attribute Details

#slot_optionsObject (readonly)

Returns the value of attribute slot_options.



27
28
29
# File 'lib/temporalio/worker/tuner.rb', line 27

def slot_options
  @slot_options
end

#tuner_optionsObject (readonly)

Returns the value of attribute tuner_options.



27
28
29
# File 'lib/temporalio/worker/tuner.rb', line 27

def tuner_options
  @tuner_options
end