Module: Rubypress::XMLRPCRetryable
- Includes:
- Retryable
- Defined in:
- lib/rubypress/xml_rpc_retryable.rb
Constant Summary collapse
- RUBY_EXCEPTIONS =
[ Timeout::Error, Errno::EPIPE ]
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.extended(instance) ⇒ Object
12 13 14 15 |
# File 'lib/rubypress/xml_rpc_retryable.rb', line 12 def self.extended(instance) instance.singleton_class.send(:alias_method, :call_without_retry, :call) instance.singleton_class.send(:alias_method, :call, :call_with_retry) end |
Instance Method Details
#call_with_retry(method, *args) ⇒ Object
17 18 19 20 21 |
# File 'lib/rubypress/xml_rpc_retryable.rb', line 17 def call_with_retry(method, *args) retryable on: RUBY_EXCEPTIONS do call_without_retry(method, *args) end end |