Class: SolidObjects::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/solid_objects/configuration.rb,
sig/generated/lib/solid_objects/configuration.rbs

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.

RBS:

  • () -> void



72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
# File 'lib/solid_objects/configuration.rb', line 72

def initialize
  @table_name_prefix = "solid_objects_"
  @polling_interval = 0.1
  @sync_polling_interval = 0.05
  @lease_duration = 30.0
  @lease_renewal_interval = 10.0
  @idle_deactivation_timeout = 30.0
  @max_messages_per_activation_pass = 50
  @max_activation_duration = 5.0
  @max_mailbox_length = 10_000
  @claim_scan_limit = 100
  @max_payload_bytes = 1.megabyte
  @max_state_bytes = 5.megabytes
  @max_result_bytes = 1.megabyte
  @max_attempts = 5
  @retry_delay = ->(attempt) { [ 2**(attempt - 1), 60 ].min.to_f }
  @process_heartbeat_interval = 15.0
  @process_alive_threshold = 60.0
  @shutdown_timeout = 15.0
  @worker_count = 1
  @effect_worker_count = 1
  @broadcast_worker_count = 1
  @reminder_scheduler_count = 1
  @connects_to = nil
  @stream_signing_secret = nil
  @broadcast_adapter = nil
  @wake_up_adapter = nil
  @logger = if defined?(Rails) && Rails.respond_to?(:logger) && Rails.logger
    Rails.logger
  else
    Logger.new($stdout)
  end
  @authorize_message = ->(**) { false }
  @authorize_query = ->(**) { false }
  @authorize_destroy = ->(**) { false }
  @authorize_subscription = ->(**) { false }
  @authorize_administration = ->(**) { false }
end

Instance Attribute Details

#authorize_administrationObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def authorize_administration
  @authorize_administration
end

#authorize_destroyObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def authorize_destroy
  @authorize_destroy
end

#authorize_messageObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def authorize_message
  @authorize_message
end

#authorize_queryObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def authorize_query
  @authorize_query
end

#authorize_subscriptionObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def authorize_subscription
  @authorize_subscription
end

#broadcast_adapterObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def broadcast_adapter
  @broadcast_adapter
end

#broadcast_worker_countObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def broadcast_worker_count
  @broadcast_worker_count
end

#claim_scan_limitObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def claim_scan_limit
  @claim_scan_limit
end

#connects_toObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def connects_to
  @connects_to
end

#effect_worker_countObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def effect_worker_count
  @effect_worker_count
end

#idle_deactivation_timeoutObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def idle_deactivation_timeout
  @idle_deactivation_timeout
end

#lease_durationObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def lease_duration
  @lease_duration
end

#lease_renewal_intervalObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def lease_renewal_interval
  @lease_renewal_interval
end

#loggerObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def logger
  @logger
end

#max_activation_durationObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def max_activation_duration
  @max_activation_duration
end

#max_attemptsObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def max_attempts
  @max_attempts
end

#max_mailbox_lengthObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def max_mailbox_length
  @max_mailbox_length
end

#max_messages_per_activation_passObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def max_messages_per_activation_pass
  @max_messages_per_activation_pass
end

#max_payload_bytesObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def max_payload_bytes
  @max_payload_bytes
end

#max_result_bytesObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def max_result_bytes
  @max_result_bytes
end

#max_state_bytesObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def max_state_bytes
  @max_state_bytes
end

#polling_intervalObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def polling_interval
  @polling_interval
end

#process_alive_thresholdObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def process_alive_threshold
  @process_alive_threshold
end

#process_heartbeat_intervalObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def process_heartbeat_interval
  @process_heartbeat_interval
end

#reminder_scheduler_countObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def reminder_scheduler_count
  @reminder_scheduler_count
end

#retry_delayObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def retry_delay
  @retry_delay
end

#shutdown_timeoutObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def shutdown_timeout
  @shutdown_timeout
end

#stream_signing_secretObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def stream_signing_secret
  @stream_signing_secret
end

#sync_polling_intervalObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def sync_polling_interval
  @sync_polling_interval
end

#table_name_prefixObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def table_name_prefix
  @table_name_prefix
end

#wake_up_adapterObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def wake_up_adapter
  @wake_up_adapter
end

#worker_countObject

RBS:

  • @table_name_prefix: String

  • @polling_interval: Float

  • @sync_polling_interval: Float

  • @lease_duration: Float

  • @lease_renewal_interval: Float

  • @idle_deactivation_timeout: Float

  • @max_messages_per_activation_pass: Integer

  • @max_activation_duration: Float

  • @max_mailbox_length: Integer

  • @claim_scan_limit: Integer

  • @max_payload_bytes: Integer

  • @max_state_bytes: Integer

  • @max_result_bytes: Integer

  • @max_attempts: Integer

  • @retry_delay: Proc

  • @process_heartbeat_interval: Float

  • @process_alive_threshold: Float

  • @shutdown_timeout: Float

  • @worker_count: Integer

  • @effect_worker_count: Integer

  • @broadcast_worker_count: Integer

  • @reminder_scheduler_count: Integer

  • @connects_to: Hash[Symbol, untyped]?

  • @logger: untyped

  • @stream_signing_secret: String?

  • @broadcast_adapter: Proc?

  • @wake_up_adapter: untyped

  • @authorize_message: Proc

  • @authorize_query: Proc

  • @authorize_destroy: Proc

  • @authorize_subscription: Proc

  • @authorize_administration: Proc

Returns:

  • (Object)


38
39
40
# File 'lib/solid_objects/configuration.rb', line 38

def worker_count
  @worker_count
end

Instance Method Details

#component_countsHash[Symbol, Integer]

RBS:

  • () -> Hash[Symbol, Integer]

Returns:

  • (Hash[Symbol, Integer])


159
160
161
162
163
164
165
166
# File 'lib/solid_objects/configuration.rb', line 159

def component_counts
  {
    worker_count:,
    effect_worker_count:,
    broadcast_worker_count:,
    reminder_scheduler_count:
  }
end

#positive_valuesHash[Symbol, Numeric]

RBS:

  • () -> Hash[Symbol, Numeric]

Returns:

  • (Hash[Symbol, Numeric])


138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
# File 'lib/solid_objects/configuration.rb', line 138

def positive_values
  {
    polling_interval:,
    sync_polling_interval:,
    lease_duration:,
    lease_renewal_interval:,
    max_messages_per_activation_pass:,
    max_activation_duration:,
    max_mailbox_length:,
    claim_scan_limit:,
    max_payload_bytes:,
    max_state_bytes:,
    max_result_bytes:,
    max_attempts:,
    process_heartbeat_interval:,
    process_alive_threshold:,
    shutdown_timeout:
  }
end

#validate!self

RBS:

  • () -> self

Returns:

  • (self)


112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
# File 'lib/solid_objects/configuration.rb', line 112

def validate!
  unless table_name_prefix.match?(/\A[a-z][a-z0-9_]*\z/)
    raise ArgumentError, "table_name_prefix must contain lowercase letters, digits, and underscores"
  end

  unless lease_duration > lease_renewal_interval
    raise ArgumentError, "lease_duration must be greater than lease_renewal_interval"
  end

  component_counts.each do |name, value|
    raise ArgumentError, "#{name} must not be negative" if value.negative?
  end
  if component_counts.values.sum.zero?
    raise ArgumentError, "at least one runtime component must be configured"
  end

  positive_values.each do |name, value|
    raise ArgumentError, "#{name} must be positive" unless value.positive?
  end

  self
end