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.
Reads multiple values at once from the cache. Options can be passed
def read_multi(*names)
  return {} if names.empty?
  options = names.extract_options!
  options = merged_options(options)
  instrument_multi :read_multi, names, options do |payload|
    read_multi_entries(names, **options, event: payload).tap do |results|
      payload[:hits] = results.keys
    end
  end
end