Class: Sunspot::SessionProxy::Retry5xxSessionProxy
- Inherits:
-
AbstractSessionProxy
- Object
- AbstractSessionProxy
- Sunspot::SessionProxy::Retry5xxSessionProxy
- Defined in:
- lib/sunspot/session_proxy/retry_5xx_session_proxy.rb
Defined Under Namespace
Classes: RetryHandler
Instance Attribute Summary collapse
-
#retry_handler ⇒ Object
readonly
Returns the value of attribute retry_handler.
-
#search_session ⇒ Object
readonly
Returns the value of attribute search_session.
Instance Method Summary collapse
-
#initialize(search_session = Sunspot.session) ⇒ Retry5xxSessionProxy
constructor
A new instance of Retry5xxSessionProxy.
- #rescued_exception(method, e) ⇒ Object
Methods inherited from AbstractSessionProxy
Constructor Details
#initialize(search_session = Sunspot.session) ⇒ Retry5xxSessionProxy
Returns a new instance of Retry5xxSessionProxy.
51 52 53 54 |
# File 'lib/sunspot/session_proxy/retry_5xx_session_proxy.rb', line 51 def initialize(search_session = Sunspot.session) @search_session = search_session @retry_handler = RetryHandler.new(search_session) end |
Instance Attribute Details
#retry_handler ⇒ Object (readonly)
Returns the value of attribute retry_handler.
44 45 46 |
# File 'lib/sunspot/session_proxy/retry_5xx_session_proxy.rb', line 44 def retry_handler @retry_handler end |
#search_session ⇒ Object (readonly)
Returns the value of attribute search_session.
43 44 45 |
# File 'lib/sunspot/session_proxy/retry_5xx_session_proxy.rb', line 43 def search_session @search_session end |
Instance Method Details
#rescued_exception(method, e) ⇒ Object
56 57 58 |
# File 'lib/sunspot/session_proxy/retry_5xx_session_proxy.rb', line 56 def rescued_exception(method, e) $stderr.puts("Exception in #{method}: #{e.}") end |