Exception: Solr::Errors::SolrConnectionFailedError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/solr/errors/solr_connection_failed_error.rb

Instance Method Summary collapse

Constructor Details

#initialize(solr_url_errors) ⇒ SolrConnectionFailedError

Returns a new instance of SolrConnectionFailedError.



4
5
6
7
8
9
10
11
# File 'lib/solr/errors/solr_connection_failed_error.rb', line 4

def initialize(solr_url_errors)
  urls_message = solr_url_errors.map { |url, error| "[#{url}] #{error}" }.join("\n")
  message = <<~MESSAGE
    Could not connect to any available solr instance:
    #{urls_message}
  MESSAGE
  super(message)
end