Exception: Turbocable::HealthCheckError

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

Overview

Raised by Turbocable.healthcheck! when the NATS connection or JetStream stream is unreachable. Carries the underlying cause for diagnosis.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, cause: nil) ⇒ HealthCheckError

Returns a new instance of HealthCheckError.

Parameters:

  • message (String)
  • cause (Exception, nil) (defaults to: nil)


77
78
79
80
# File 'lib/turbocable/errors.rb', line 77

def initialize(message, cause: nil)
  super(message)
  @cause = cause
end

Instance Attribute Details

#causeException? (readonly)

Returns:

  • (Exception, nil)


73
74
75
# File 'lib/turbocable/errors.rb', line 73

def cause
  @cause
end