Module | Typhoeus::Hydra::Memoizable |
In: |
lib/typhoeus/hydra/memoizable.rb
|
This module handles the GET request memoization on the hydra side. Memoization needs to be turned on:
Typhoeus.configure do |config| config.memoize = true end
@api private
Overrides add in order to check before if request is memoizable and already in memory. If thats the case, super is not called, instead the response is set and the on_complete callback called.
@example Add the request.
hydra.add(request)
@param [ Request ] request The request to add.
@return [ Request ] The added request.