Refactor (ruby) redis configuration (#31694)
This commit is contained in:
parent
a23b3747ac
commit
388d5473e1
20 changed files with 295 additions and 90 deletions
|
@ -2,7 +2,7 @@
|
|||
|
||||
class FixReblogsInFeeds < ActiveRecord::Migration[5.1]
|
||||
def up
|
||||
redis = RedisConfiguration.pool.checkout
|
||||
redis = RedisConnection.pool.checkout
|
||||
fm = FeedManager.instance
|
||||
|
||||
# Old scheme:
|
||||
|
|
|
@ -4,7 +4,7 @@ class MigrateUnavailableInboxes < ActiveRecord::Migration[5.2]
|
|||
disable_ddl_transaction!
|
||||
|
||||
def up
|
||||
redis = RedisConfiguration.pool.checkout
|
||||
redis = RedisConnection.pool.checkout
|
||||
urls = redis.smembers('unavailable_inboxes')
|
||||
|
||||
hosts = urls.filter_map do |url|
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue