Class: HTTP::Retriable::Client
- Defined in:
- lib/http/retriable/client.rb
Overview
Retriable version of HTTP::Client.
Constant Summary
Constants inherited from Client
Instance Method Summary collapse
-
#initialize(performer, options) ⇒ Client
constructor
A new instance of Client.
-
#perform(req, options) ⇒ Object
Overriden version of
HTTP::Client#make_request
.
Methods inherited from Client
#build_request, #close, #persistent?, #request
Methods included from Chainable
#accept, #auth, #basic_auth, #build_request, #connect, #cookies, #default_options, #default_options=, #delete, #encoding, #follow, #get, #head, #headers, #nodelay, #options, #patch, #persistent, #post, #put, #request, #retriable, #timeout, #trace, #use, #via
Methods included from Base64
Constructor Details
#initialize(performer, options) ⇒ Client
Returns a new instance of Client.
13 14 15 16 |
# File 'lib/http/retriable/client.rb', line 13 def initialize(performer, ) @performer = performer super() end |
Instance Method Details
#perform(req, options) ⇒ Object
Overriden version of HTTP::Client#make_request
.
Monitors request/response phase with performer.
23 24 25 |
# File 'lib/http/retriable/client.rb', line 23 def perform(req, ) @performer.perform(self, req) { super(req, ) } end |