Exception: KubeMQ::ConnectionNotReadyError

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

Overview

Raised when an operation is attempted before the connection is established.

The transport exists but has not reached the READY state. Retryable — wait for the reconnect policy to establish the connection.

See Also:

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 = 'Connection is not ready', **kwargs) ⇒ ConnectionNotReadyError

Returns a new instance of ConnectionNotReadyError.



208
209
210
211
212
# File 'lib/kubemq/errors.rb', line 208

def initialize(message = 'Connection is not ready', **kwargs)
  kwargs[:code] ||= ErrorCode::CONNECTION_NOT_READY
  kwargs[:retryable] = false unless kwargs.key?(:retryable)
  super
end