class ActiveSupport::Cache::Store

def read_multi(*names)

Returns a hash mapping the names provided to the values found.

Some cache implementation may optimize this method.

in the last argument.
Read multiple values at once from the cache. Options can be passed
def read_multi(*names)
  options = names.extract_options!
  options = merged_options(options)
  results = {}
  names.each do |name|
    key = namespaced_key(name, options)
    entry = read_entry(key, options)
    if entry
      if entry.expired?
        delete_entry(key, options)
      else
        results[name] = entry.value
      end
    end
  end
  results
end