Exception: KubeMQ::TimeoutError

Inherits:
Error
  • Object
show all
Defined in:
lib/kubemq/errors.rb

Overview

Note:

Default error code is CONNECTION_TIMEOUT.

Raised when an operation exceeds its deadline.

Retryable by default. Increase the timeout or investigate broker load if this error persists.

Instance Attribute Summary

Attributes inherited from Error

#channel, #code, #details, #operation, #request_id, #suggestion

Instance Method Summary collapse

Methods inherited from Error

#cause, #retryable?, #to_s

Constructor Details

#initialize(message, **kwargs) ⇒ TimeoutError

Returns a new instance of TimeoutError.



132
133
134
135
136
# File 'lib/kubemq/errors.rb', line 132

def initialize(message, **kwargs)
  kwargs[:retryable] = true unless kwargs.key?(:retryable)
  kwargs[:code] ||= ErrorCode::CONNECTION_TIMEOUT
  super
end