ReactiveCaching#clear_reactive_cache! should clear the not keep the cache alive
This commit is contained in:
parent
4b0ff7c742
commit
2535834f8a
3 changed files with 8 additions and 0 deletions
|
@ -74,6 +74,7 @@ module ReactiveCaching
|
||||||
|
|
||||||
def clear_reactive_cache!(*args)
|
def clear_reactive_cache!(*args)
|
||||||
Rails.cache.delete(full_reactive_cache_key(*args))
|
Rails.cache.delete(full_reactive_cache_key(*args))
|
||||||
|
Rails.cache.delete(alive_reactive_cache_key(*args))
|
||||||
end
|
end
|
||||||
|
|
||||||
def exclusively_update_reactive_cache!(*args)
|
def exclusively_update_reactive_cache!(*args)
|
||||||
|
|
6
changelogs/unreleased/reactive-caching-alive-bug.yml
Normal file
6
changelogs/unreleased/reactive-caching-alive-bug.yml
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
---
|
||||||
|
title: Updates ReactiveCaching clear_reactive_caching method to clear both data and
|
||||||
|
alive caching
|
||||||
|
merge_request: 19311
|
||||||
|
author:
|
||||||
|
type: fixed
|
|
@ -94,6 +94,7 @@ describe ReactiveCaching, :use_clean_rails_memory_store_caching do
|
||||||
end
|
end
|
||||||
|
|
||||||
it { expect(instance.result).to be_nil }
|
it { expect(instance.result).to be_nil }
|
||||||
|
it { expect(reactive_cache_alive?(instance)).to be_falsy }
|
||||||
end
|
end
|
||||||
|
|
||||||
describe '#exclusively_update_reactive_cache!' do
|
describe '#exclusively_update_reactive_cache!' do
|
||||||
|
|
Loading…
Reference in a new issue