Module: Ipregistry::Cache

Defined in:
lib/ipregistry/cache.rb

Overview

Caching backends used by Client to memoize IP lookups.

Only successful single and batch IP lookups are cached. Origin lookups are never cached, because the requester IP is only known from the response.

A cache is any object responding to get(key), set(key, value), delete(key), and clear, and safe for concurrent use from multiple threads — bring your own backend (Redis, Rails.cache, ...) by satisfying that interface.

Defined Under Namespace

Classes: Memory, None