Exception: Nomad::HTTPConnectionError

Inherits:
NomadError
  • Object
show all
Defined in:
lib/nomad/errors.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(address, exception) ⇒ HTTPConnectionError

Returns a new instance of HTTPConnectionError.



7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# File 'lib/nomad/errors.rb', line 7

def initialize(address, exception)
  @address = address
  @exception = exception

  super <<-EOH
The Nomad server at `#{address}' is not currently
accepting connections. Please ensure that the server is running and that your
authentication information is correct.

The original error was `#{exception.class}'. Additional information (if any) is
shown below:

#{exception.message}

Please refer to the documentation for more help.
EOH
end

Instance Attribute Details

#addressObject (readonly)

Returns the value of attribute address.



5
6
7
# File 'lib/nomad/errors.rb', line 5

def address
  @address
end

Instance Method Details

#original_exceptionObject



25
26
27
# File 'lib/nomad/errors.rb', line 25

def original_exception
  @exception
end