activesupport 6.0.2.2 → 6.0.3.rc1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of activesupport might be problematic. Click here for more details.

Files changed (67) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +27 -0
  3. data/README.rdoc +1 -1
  4. data/lib/active_support/backtrace_cleaner.rb +0 -1
  5. data/lib/active_support/cache.rb +29 -28
  6. data/lib/active_support/cache/file_store.rb +7 -8
  7. data/lib/active_support/cache/mem_cache_store.rb +8 -8
  8. data/lib/active_support/cache/memory_store.rb +6 -7
  9. data/lib/active_support/cache/null_store.rb +3 -3
  10. data/lib/active_support/cache/redis_cache_store.rb +7 -7
  11. data/lib/active_support/cache/strategy/local_cache.rb +23 -23
  12. data/lib/active_support/callbacks.rb +0 -3
  13. data/lib/active_support/concurrency/load_interlock_aware_monitor.rb +18 -0
  14. data/lib/active_support/concurrency/share_lock.rb +0 -1
  15. data/lib/active_support/core_ext/array/conversions.rb +5 -5
  16. data/lib/active_support/core_ext/date_and_time/zones.rb +0 -1
  17. data/lib/active_support/core_ext/date_time/conversions.rb +0 -1
  18. data/lib/active_support/core_ext/hash/conversions.rb +1 -1
  19. data/lib/active_support/core_ext/module/delegation.rb +8 -1
  20. data/lib/active_support/core_ext/module/introspection.rb +1 -0
  21. data/lib/active_support/core_ext/object/try.rb +2 -0
  22. data/lib/active_support/core_ext/range/each.rb +0 -1
  23. data/lib/active_support/core_ext/string/output_safety.rb +0 -1
  24. data/lib/active_support/dependencies.rb +0 -2
  25. data/lib/active_support/dependencies/zeitwerk_integration.rb +0 -1
  26. data/lib/active_support/deprecation/method_wrappers.rb +12 -6
  27. data/lib/active_support/deprecation/proxy_wrappers.rb +5 -1
  28. data/lib/active_support/descendants_tracker.rb +0 -1
  29. data/lib/active_support/duration.rb +13 -11
  30. data/lib/active_support/duration/iso8601_parser.rb +0 -1
  31. data/lib/active_support/duration/iso8601_serializer.rb +0 -1
  32. data/lib/active_support/encrypted_file.rb +1 -1
  33. data/lib/active_support/evented_file_update_checker.rb +0 -1
  34. data/lib/active_support/file_update_checker.rb +0 -1
  35. data/lib/active_support/gem_version.rb +2 -2
  36. data/lib/active_support/inflector/inflections.rb +0 -1
  37. data/lib/active_support/inflector/methods.rb +1 -2
  38. data/lib/active_support/json/decoding.rb +0 -1
  39. data/lib/active_support/lazy_load_hooks.rb +0 -1
  40. data/lib/active_support/locale/en.rb +4 -2
  41. data/lib/active_support/log_subscriber.rb +0 -1
  42. data/lib/active_support/logger.rb +1 -1
  43. data/lib/active_support/message_encryptor.rb +1 -1
  44. data/lib/active_support/message_verifier.rb +2 -2
  45. data/lib/active_support/messages/metadata.rb +3 -2
  46. data/lib/active_support/messages/rotator.rb +4 -4
  47. data/lib/active_support/multibyte/chars.rb +1 -2
  48. data/lib/active_support/multibyte/unicode.rb +0 -1
  49. data/lib/active_support/notifications/instrumenter.rb +0 -1
  50. data/lib/active_support/number_helper.rb +4 -0
  51. data/lib/active_support/number_helper/number_converter.rb +4 -5
  52. data/lib/active_support/number_helper/number_to_currency_converter.rb +7 -8
  53. data/lib/active_support/number_helper/number_to_delimited_converter.rb +0 -1
  54. data/lib/active_support/number_helper/number_to_human_converter.rb +0 -1
  55. data/lib/active_support/number_helper/number_to_human_size_converter.rb +0 -1
  56. data/lib/active_support/number_helper/number_to_phone_converter.rb +0 -1
  57. data/lib/active_support/number_helper/number_to_rounded_converter.rb +0 -1
  58. data/lib/active_support/option_merger.rb +21 -3
  59. data/lib/active_support/ordered_options.rb +4 -0
  60. data/lib/active_support/parameter_filter.rb +1 -2
  61. data/lib/active_support/string_inquirer.rb +0 -1
  62. data/lib/active_support/testing/parallelization.rb +8 -2
  63. data/lib/active_support/testing/stream.rb +0 -1
  64. data/lib/active_support/testing/time_helpers.rb +0 -2
  65. data/lib/active_support/xml_mini.rb +0 -1
  66. data/lib/active_support/xml_mini/jdom.rb +0 -1
  67. metadata +15 -9
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7bf8048c7cb74c8a78b675b8a60c273101aeeae4160b72754fa4f25cf99d32f0
4
- data.tar.gz: d7863b004d5dc872914d96a429f7a4046d3adcf738b9a6d6ac18080819fc1f7a
3
+ metadata.gz: f9a3640584c7bec116a2753b05a7bce56fe1f8c20792cd0a203c27b7f32cbc4c
4
+ data.tar.gz: 4250f2f8de4fd670f64fd3bb7b92c35cf494ad54bc8bc7aa6e9e37509ae49892
5
5
  SHA512:
6
- metadata.gz: 70a16e7d86c63ddd518f5013d00b2e4730a3a1d9847f8e31d151c40e250934f216eeb4c4277921d869fff015479dc1aeca05c8b87e782c75dcebbed1ff8cd776
7
- data.tar.gz: 549b1f814d15ec89d3468425f976a6c38a5e50a3827088d3aef600fdfd1666fe84ca8ab2afc277d491e3dcd1a712c489bd8dc3eca4e1ad40a272471c7df58998
6
+ metadata.gz: ebeefc050565be0566159148f0e4fdcf1735c0538f8b3c79f7f865522497284e7c298929b9d78c2f60bda713323ae3fe8119a2b52578f3679e992538b1cb318f
7
+ data.tar.gz: 102293ec9dbc84dbff803c972960684d73edb62b06e8028618825976ee83e90629bc8075ba66f21837dc322568b053f2063a3935d11a14e02d885a72a1dc5ba3
@@ -1,3 +1,30 @@
1
+ ## Rails 6.0.3.rc1 (April 30, 2020) ##
2
+
3
+ * `Array#to_sentence` no longer returns a frozen string.
4
+
5
+ Before:
6
+
7
+ ['one', 'two'].to_sentence.frozen?
8
+ # => true
9
+
10
+ After:
11
+
12
+ ['one', 'two'].to_sentence.frozen?
13
+ # => false
14
+
15
+ *Nicolas Dular*
16
+
17
+ * Update `ActiveSupport::Messages::Metadata#fresh?` to work for cookies with expiry set when
18
+ `ActiveSupport.parse_json_times = true`.
19
+
20
+ *Christian Gregg*
21
+
22
+
23
+ ## Rails 6.0.2.2 (March 19, 2020) ##
24
+
25
+ * No changes.
26
+
27
+
1
28
  ## Rails 6.0.2.1 (December 18, 2019) ##
2
29
 
3
30
  * No changes.
@@ -37,4 +37,4 @@ Bug reports for the Ruby on Rails project can be filed here:
37
37
 
38
38
  Feature requests should be discussed on the rails-core mailing list here:
39
39
 
40
- * https://groups.google.com/forum/?fromgroups#!forum/rubyonrails-core
40
+ * https://discuss.rubyonrails.org/c/rubyonrails-core
@@ -85,7 +85,6 @@ module ActiveSupport
85
85
  end
86
86
 
87
87
  private
88
-
89
88
  FORMATTED_GEMS_PATTERN = /\A[^\/]+ \([\w.]+\) /
90
89
 
91
90
  def add_gem_filter
@@ -52,12 +52,13 @@ module ActiveSupport
52
52
  #
53
53
  # ActiveSupport::Cache.lookup_store(MyOwnCacheStore.new)
54
54
  # # => returns MyOwnCacheStore.new
55
- def lookup_store(*store_option)
56
- store, *parameters = *Array.wrap(store_option).flatten
57
-
55
+ def lookup_store(store = nil, *parameters)
58
56
  case store
59
57
  when Symbol
60
- retrieve_store_class(store).new(*parameters)
58
+ options = parameters.extract_options!
59
+ retrieve_store_class(store).new(*parameters, **options)
60
+ when Array
61
+ lookup_store(*store)
61
62
  when nil
62
63
  ActiveSupport::Cache::MemoryStore.new
63
64
  else
@@ -318,7 +319,7 @@ module ActiveSupport
318
319
 
319
320
  entry = nil
320
321
  instrument(:read, name, options) do |payload|
321
- cached_entry = read_entry(key, options) unless options[:force]
322
+ cached_entry = read_entry(key, **options) unless options[:force]
322
323
  entry = handle_expired_entry(cached_entry, key, options)
323
324
  entry = nil if entry && entry.mismatched?(normalize_version(name, options))
324
325
  payload[:super_operation] = :fetch if payload
@@ -326,9 +327,9 @@ module ActiveSupport
326
327
  end
327
328
 
328
329
  if entry
329
- get_entry_value(entry, name, options)
330
+ get_entry_value(entry, name, **options)
330
331
  else
331
- save_block_result_to_cache(name, options) { |_name| yield _name }
332
+ save_block_result_to_cache(name, **options) { |_name| yield _name }
332
333
  end
333
334
  elsif options && options[:force]
334
335
  raise ArgumentError, "Missing block: Calling `Cache#fetch` with `force: true` requires a block."
@@ -352,11 +353,11 @@ module ActiveSupport
352
353
  version = normalize_version(name, options)
353
354
 
354
355
  instrument(:read, name, options) do |payload|
355
- entry = read_entry(key, options)
356
+ entry = read_entry(key, **options)
356
357
 
357
358
  if entry
358
359
  if entry.expired?
359
- delete_entry(key, options)
360
+ delete_entry(key, **options)
360
361
  payload[:hit] = false if payload
361
362
  nil
362
363
  elsif entry.mismatched?(version)
@@ -384,7 +385,7 @@ module ActiveSupport
384
385
  options = merged_options(options)
385
386
 
386
387
  instrument :read_multi, names, options do |payload|
387
- read_multi_entries(names, options).tap do |results|
388
+ read_multi_entries(names, **options).tap do |results|
388
389
  payload[:hits] = results.keys
389
390
  end
390
391
  end
@@ -396,10 +397,10 @@ module ActiveSupport
396
397
 
397
398
  instrument :write_multi, hash, options do |payload|
398
399
  entries = hash.each_with_object({}) do |(name, value), memo|
399
- memo[normalize_key(name, options)] = Entry.new(value, options.merge(version: normalize_version(name, options)))
400
+ memo[normalize_key(name, options)] = Entry.new(value, **options.merge(version: normalize_version(name, options)))
400
401
  end
401
402
 
402
- write_multi_entries entries, options
403
+ write_multi_entries entries, **options
403
404
  end
404
405
  end
405
406
 
@@ -438,7 +439,7 @@ module ActiveSupport
438
439
  options = merged_options(options)
439
440
 
440
441
  instrument :read_multi, names, options do |payload|
441
- reads = read_multi_entries(names, options)
442
+ reads = read_multi_entries(names, **options)
442
443
  writes = {}
443
444
  ordered = names.each_with_object({}) do |name, hash|
444
445
  hash[name] = reads.fetch(name) { writes[name] = yield(name) }
@@ -447,7 +448,7 @@ module ActiveSupport
447
448
  payload[:hits] = reads.keys
448
449
  payload[:super_operation] = :fetch_multi
449
450
 
450
- write_multi(writes, options)
451
+ write_multi(writes, **options)
451
452
 
452
453
  ordered
453
454
  end
@@ -460,8 +461,8 @@ module ActiveSupport
460
461
  options = merged_options(options)
461
462
 
462
463
  instrument(:write, name, options) do
463
- entry = Entry.new(value, options.merge(version: normalize_version(name, options)))
464
- write_entry(normalize_key(name, options), entry, options)
464
+ entry = Entry.new(value, **options.merge(version: normalize_version(name, options)))
465
+ write_entry(normalize_key(name, options), entry, **options)
465
466
  end
466
467
  end
467
468
 
@@ -472,7 +473,7 @@ module ActiveSupport
472
473
  options = merged_options(options)
473
474
 
474
475
  instrument(:delete, name) do
475
- delete_entry(normalize_key(name, options), options)
476
+ delete_entry(normalize_key(name, options), **options)
476
477
  end
477
478
  end
478
479
 
@@ -483,7 +484,7 @@ module ActiveSupport
483
484
  options = merged_options(options)
484
485
 
485
486
  instrument(:exist?, name) do
486
- entry = read_entry(normalize_key(name, options), options)
487
+ entry = read_entry(normalize_key(name, options), **options)
487
488
  (entry && !entry.expired? && !entry.mismatched?(normalize_version(name, options))) || false
488
489
  end
489
490
  end
@@ -556,28 +557,28 @@ module ActiveSupport
556
557
 
557
558
  # Reads an entry from the cache implementation. Subclasses must implement
558
559
  # this method.
559
- def read_entry(key, options)
560
+ def read_entry(key, **options)
560
561
  raise NotImplementedError.new
561
562
  end
562
563
 
563
564
  # Writes an entry to the cache implementation. Subclasses must implement
564
565
  # this method.
565
- def write_entry(key, entry, options)
566
+ def write_entry(key, entry, **options)
566
567
  raise NotImplementedError.new
567
568
  end
568
569
 
569
570
  # Reads multiple entries from the cache implementation. Subclasses MAY
570
571
  # implement this method.
571
- def read_multi_entries(names, options)
572
+ def read_multi_entries(names, **options)
572
573
  results = {}
573
574
  names.each do |name|
574
575
  key = normalize_key(name, options)
575
576
  version = normalize_version(name, options)
576
- entry = read_entry(key, options)
577
+ entry = read_entry(key, **options)
577
578
 
578
579
  if entry
579
580
  if entry.expired?
580
- delete_entry(key, options)
581
+ delete_entry(key, **options)
581
582
  elsif entry.mismatched?(version)
582
583
  # Skip mismatched versions
583
584
  else
@@ -590,15 +591,15 @@ module ActiveSupport
590
591
 
591
592
  # Writes multiple entries to the cache implementation. Subclasses MAY
592
593
  # implement this method.
593
- def write_multi_entries(hash, options)
594
+ def write_multi_entries(hash, **options)
594
595
  hash.each do |key, entry|
595
- write_entry key, entry, options
596
+ write_entry key, entry, **options
596
597
  end
597
598
  end
598
599
 
599
600
  # Deletes an entry from the cache implementation. Subclasses must
600
601
  # implement this method.
601
- def delete_entry(key, options)
602
+ def delete_entry(key, **options)
602
603
  raise NotImplementedError.new
603
604
  end
604
605
 
@@ -699,7 +700,7 @@ module ActiveSupport
699
700
  entry.expires_at = Time.now + race_ttl
700
701
  write_entry(key, entry, expires_in: race_ttl * 2)
701
702
  else
702
- delete_entry(key, options)
703
+ delete_entry(key, **options)
703
704
  end
704
705
  entry = nil
705
706
  end
@@ -711,7 +712,7 @@ module ActiveSupport
711
712
  entry.value
712
713
  end
713
714
 
714
- def save_block_result_to_cache(name, options)
715
+ def save_block_result_to_cache(name, **options)
715
716
  result = instrument(:generate, name, options) do
716
717
  yield(name)
717
718
  end
@@ -36,15 +36,15 @@ module ActiveSupport
36
36
  def clear(options = nil)
37
37
  root_dirs = (Dir.children(cache_path) - GITKEEP_FILES)
38
38
  FileUtils.rm_r(root_dirs.collect { |f| File.join(cache_path, f) })
39
- rescue Errno::ENOENT
39
+ rescue Errno::ENOENT, Errno::ENOTEMPTY
40
40
  end
41
41
 
42
42
  # Preemptively iterates through all stored keys and removes the ones which have expired.
43
43
  def cleanup(options = nil)
44
44
  options = merged_options(options)
45
45
  search_dir(cache_path) do |fname|
46
- entry = read_entry(fname, options)
47
- delete_entry(fname, options) if entry && entry.expired?
46
+ entry = read_entry(fname, **options)
47
+ delete_entry(fname, **options) if entry && entry.expired?
48
48
  end
49
49
  end
50
50
 
@@ -66,14 +66,13 @@ module ActiveSupport
66
66
  matcher = key_matcher(matcher, options)
67
67
  search_dir(cache_path) do |path|
68
68
  key = file_path_key(path)
69
- delete_entry(path, options) if key.match(matcher)
69
+ delete_entry(path, **options) if key.match(matcher)
70
70
  end
71
71
  end
72
72
  end
73
73
 
74
74
  private
75
-
76
- def read_entry(key, options)
75
+ def read_entry(key, **options)
77
76
  if File.exist?(key)
78
77
  File.open(key) { |f| Marshal.load(f) }
79
78
  end
@@ -82,14 +81,14 @@ module ActiveSupport
82
81
  nil
83
82
  end
84
83
 
85
- def write_entry(key, entry, options)
84
+ def write_entry(key, entry, **options)
86
85
  return false if options[:unless_exist] && File.exist?(key)
87
86
  ensure_cache_path(File.dirname(key))
88
87
  File.atomic_write(key, cache_path) { |f| Marshal.dump(entry, f) }
89
88
  true
90
89
  end
91
90
 
92
- def delete_entry(key, options)
91
+ def delete_entry(key, **options)
93
92
  if File.exist?(key)
94
93
  begin
95
94
  File.delete(key)
@@ -28,7 +28,7 @@ module ActiveSupport
28
28
  # Provide support for raw values in the local cache strategy.
29
29
  module LocalCacheWithRaw # :nodoc:
30
30
  private
31
- def read_entry(key, options)
31
+ def read_entry(key, **options)
32
32
  entry = super
33
33
  if options[:raw] && local_cache && entry
34
34
  entry = deserialize_entry(entry.value)
@@ -36,11 +36,11 @@ module ActiveSupport
36
36
  entry
37
37
  end
38
38
 
39
- def write_entry(key, entry, options)
39
+ def write_entry(key, entry, **options)
40
40
  if options[:raw] && local_cache
41
41
  raw_entry = Entry.new(entry.value.to_s)
42
42
  raw_entry.expires_at = entry.expires_at
43
- super(key, raw_entry, options)
43
+ super(key, raw_entry, **options)
44
44
  else
45
45
  super
46
46
  end
@@ -142,12 +142,12 @@ module ActiveSupport
142
142
 
143
143
  private
144
144
  # Read an entry from the cache.
145
- def read_entry(key, options)
145
+ def read_entry(key, **options)
146
146
  rescue_error_with(nil) { deserialize_entry(@data.with { |c| c.get(key, options) }) }
147
147
  end
148
148
 
149
149
  # Write an entry to the cache.
150
- def write_entry(key, entry, options)
150
+ def write_entry(key, entry, **options)
151
151
  method = options && options[:unless_exist] ? :add : :set
152
152
  value = options[:raw] ? entry.value.to_s : entry
153
153
  expires_in = options[:expires_in].to_i
@@ -156,12 +156,12 @@ module ActiveSupport
156
156
  expires_in += 5.minutes
157
157
  end
158
158
  rescue_error_with false do
159
- @data.with { |c| c.send(method, key, value, expires_in, options) }
159
+ @data.with { |c| c.send(method, key, value, expires_in, **options) }
160
160
  end
161
161
  end
162
162
 
163
163
  # Reads multiple entries from the cache implementation.
164
- def read_multi_entries(names, options)
164
+ def read_multi_entries(names, **options)
165
165
  keys_to_names = Hash[names.map { |name| [normalize_key(name, options), name] }]
166
166
 
167
167
  raw_values = @data.with { |c| c.get_multi(keys_to_names.keys) }
@@ -179,7 +179,7 @@ module ActiveSupport
179
179
  end
180
180
 
181
181
  # Delete an entry from the cache.
182
- def delete_entry(key, options)
182
+ def delete_entry(key, **options)
183
183
  rescue_error_with(false) { @data.with { |c| c.delete(key) } }
184
184
  end
185
185
 
@@ -51,7 +51,7 @@ module ActiveSupport
51
51
  keys = synchronize { @data.keys }
52
52
  keys.each do |key|
53
53
  entry = @data[key]
54
- delete_entry(key, options) if entry && entry.expired?
54
+ delete_entry(key, **options) if entry && entry.expired?
55
55
  end
56
56
  end
57
57
  end
@@ -67,7 +67,7 @@ module ActiveSupport
67
67
  instrument(:prune, target_size, from: @cache_size) do
68
68
  keys = synchronize { @key_access.keys.sort { |a, b| @key_access[a].to_f <=> @key_access[b].to_f } }
69
69
  keys.each do |key|
70
- delete_entry(key, options)
70
+ delete_entry(key, **options)
71
71
  return if @cache_size <= target_size || (max_time && Concurrent.monotonic_time - start_time > max_time)
72
72
  end
73
73
  end
@@ -98,7 +98,7 @@ module ActiveSupport
98
98
  matcher = key_matcher(matcher, options)
99
99
  keys = synchronize { @data.keys }
100
100
  keys.each do |key|
101
- delete_entry(key, options) if key.match(matcher)
101
+ delete_entry(key, **options) if key.match(matcher)
102
102
  end
103
103
  end
104
104
  end
@@ -114,14 +114,13 @@ module ActiveSupport
114
114
  end
115
115
 
116
116
  private
117
-
118
117
  PER_ENTRY_OVERHEAD = 240
119
118
 
120
119
  def cached_size(key, entry)
121
120
  key.to_s.bytesize + entry.size + PER_ENTRY_OVERHEAD
122
121
  end
123
122
 
124
- def read_entry(key, options)
123
+ def read_entry(key, **options)
125
124
  entry = @data[key]
126
125
  synchronize do
127
126
  if entry
@@ -135,7 +134,7 @@ module ActiveSupport
135
134
  entry
136
135
  end
137
136
 
138
- def write_entry(key, entry, options)
137
+ def write_entry(key, entry, **options)
139
138
  entry.dup_value!
140
139
  synchronize do
141
140
  old_entry = @data[key]
@@ -152,7 +151,7 @@ module ActiveSupport
152
151
  end
153
152
  end
154
153
 
155
- def delete_entry(key, options)
154
+ def delete_entry(key, **options)
156
155
  synchronize do
157
156
  @key_access.delete(key)
158
157
  entry = @data.delete(key)
@@ -33,14 +33,14 @@ module ActiveSupport
33
33
  end
34
34
 
35
35
  private
36
- def read_entry(key, options)
36
+ def read_entry(key, **options)
37
37
  end
38
38
 
39
- def write_entry(key, entry, options)
39
+ def write_entry(key, entry, **options)
40
40
  true
41
41
  end
42
42
 
43
- def delete_entry(key, options)
43
+ def delete_entry(key, **options)
44
44
  false
45
45
  end
46
46
  end
@@ -74,7 +74,7 @@ module ActiveSupport
74
74
  # Support raw values in the local cache strategy.
75
75
  module LocalCacheWithRaw # :nodoc:
76
76
  private
77
- def read_entry(key, options)
77
+ def read_entry(key, **options)
78
78
  entry = super
79
79
  if options[:raw] && local_cache && entry
80
80
  entry = deserialize_entry(entry.value)
@@ -82,24 +82,24 @@ module ActiveSupport
82
82
  entry
83
83
  end
84
84
 
85
- def write_entry(key, entry, options)
85
+ def write_entry(key, entry, **options)
86
86
  if options[:raw] && local_cache
87
87
  raw_entry = Entry.new(serialize_entry(entry, raw: true))
88
88
  raw_entry.expires_at = entry.expires_at
89
- super(key, raw_entry, options)
89
+ super(key, raw_entry, **options)
90
90
  else
91
91
  super
92
92
  end
93
93
  end
94
94
 
95
- def write_multi_entries(entries, options)
95
+ def write_multi_entries(entries, **options)
96
96
  if options[:raw] && local_cache
97
97
  raw_entries = entries.map do |key, entry|
98
98
  raw_entry = Entry.new(serialize_entry(entry, raw: true))
99
99
  raw_entry.expires_at = entry.expires_at
100
100
  end.to_h
101
101
 
102
- super(raw_entries, options)
102
+ super(raw_entries, **options)
103
103
  else
104
104
  super
105
105
  end
@@ -346,13 +346,13 @@ module ActiveSupport
346
346
 
347
347
  # Store provider interface:
348
348
  # Read an entry from the cache.
349
- def read_entry(key, options = nil)
349
+ def read_entry(key, **options)
350
350
  failsafe :read_entry do
351
351
  deserialize_entry redis.with { |c| c.get(key) }
352
352
  end
353
353
  end
354
354
 
355
- def read_multi_entries(names, _options)
355
+ def read_multi_entries(names, **options)
356
356
  if mget_capable?
357
357
  read_multi_mget(*names)
358
358
  else