Sha256: 0e08d3cc0f81118e5adf8aa0a337deb19f8a5ceaff7372d4b4c6bc2f6b926020

Contents?: true

Size: 1.27 KB

Versions: 9

Compression:

Stored size: 1.27 KB

Contents

require 'active_record'
require 'rails/engine'
require 'active_support/core_ext/module'
require 'hashie'
require 'rest-client'
require 'http_store/engine'

module HttpStore
  extend ActiveSupport::Autoload

  REQUEST_KEYS  = %w[http_method url data_type headers query_params data other_params force request_valid]
  RESPONSE_KEYS = %w[status_code response response_headers response_data response_valid response_code cache_response]
  META_KEYS     = %w[request_digest client_type parent_id requestable_id requestable_type]
  TMP_KEYS      = %w[requestable response_obj]

  DIGEST_KEYS = %w[http_method url data_type data other_params requestable_id requestable_type]
  ALL_KEYS    = REQUEST_KEYS + RESPONSE_KEYS + META_KEYS + TMP_KEYS
  STORE_KEYS  = REQUEST_KEYS + RESPONSE_KEYS + META_KEYS

  class RequestError < StandardError; end

  module Helpers
    extend ActiveSupport::Autoload

    autoload :Requestable
    autoload :Responseable
    autoload :Storable
  end

  module Middleware
    extend ActiveSupport::Autoload

    autoload :RequestLog
  end

  autoload :Engine
  autoload :VERSION
  autoload :HttpLog
  autoload :Client
  autoload :Configuration

  class << self
    def config
      @config ||= Configuration.new
    end

    def configure(&block)
      yield(config)
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
http_store-0.3.18 lib/http_store.rb
http_store-0.3.17 lib/http_store.rb
http_store-0.3.16 lib/http_store.rb
http_store-0.3.15 lib/http_store.rb
http_store-0.3.14 lib/http_store.rb
http_store-0.3.13 lib/http_store.rb
http_store-0.3.12 lib/http_store.rb
http_store-0.3.11 lib/http_store.rb
http_store-0.3.10 lib/http_store.rb