Exception: GetStreamRuby::TransportError

Inherits:
StreamError
  • Object
show all
Defined in:
lib/getstream_ruby/errors.rb

Overview

Raised when no HTTP response is received: connection reset, timeout, TLS handshake failure, DNS failure. Always raised inside the matching ‘rescue` block so Ruby auto-sets `Exception#cause` to the underlying Faraday error.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message = nil, error_type: 'unknown') ⇒ TransportError

Returns a new instance of TransportError.



67
68
69
70
# File 'lib/getstream_ruby/errors.rb', line 67

def initialize(message = nil, error_type: 'unknown')
  super(message)
  @error_type = error_type
end

Instance Attribute Details

#error_typeObject (readonly)

Returns the value of attribute error_type.



65
66
67
# File 'lib/getstream_ruby/errors.rb', line 65

def error_type
  @error_type
end