Skip to content

Commit f7a82bf

Browse files
Document AS::Cache::Store#read options [ci-skip]
(cherry picked from commit a95438c)
1 parent 414351f commit f7a82bf

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

  • activesupport/lib/active_support

activesupport/lib/active_support/cache.rb

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,13 @@ def fetch(name, options = nil, &block)
342342
# <tt>:version</tt> options, both of these conditions are applied before
343343
# the data is returned.
344344
#
345-
# Options are passed to the underlying cache implementation.
345+
# ==== Options
346+
#
347+
# * +:version+ - Specifies a version for the cache entry. If the cached
348+
# version does not match the requested version, the read will be treated
349+
# as a cache miss. This feature is used to support recyclable cache keys.
350+
#
351+
# Other options will be handled by the specific cache store implementation.
346352
def read(name, options = nil)
347353
options = merged_options(options)
348354
key = normalize_key(name, options)

0 commit comments

Comments
 (0)