DEV: Make DistributedMemoizer use DistributedMutex (#16229)

Its implementation was already distributed-mutex-like, with slight differences that did not seem necessary.
This commit is contained in:
Jarek Radosz
2022-04-05 19:29:58 +02:00
committed by GitHub
parent 14778ba52e
commit 3c44bed545
3 changed files with 18 additions and 73 deletions

View File

@@ -11,12 +11,10 @@ describe StaticController do
UploadCreator.new(file, filename).create_for(Discourse.system_user.id)
end
before_all do
DistributedMemoizer.flush!
end
after do
DistributedMemoizer.flush!
Discourse.redis.scan_each(match: "memoize_*").each do |key|
Discourse.redis.del(key)
end
end
describe 'local store' do