Skip to content

A platform for community discussion. Free, open, simple.

`$redis.client` -> `$redis._client`.

Guo Xiang Tan45fe5dc793e8
diff --git a/config/unicorn.conf.rb b/config/unicorn.conf.rb
index e5f5c4d112a..01c800b1986 100644
--- a/config/unicorn.conf.rb
+++ b/config/unicorn.conf.rb
@@ -195,7 +195,7 @@ before_fork do |server, worker|
sleep 10
force_kill_rogue_sidekiq
end
- $redis.client.disconnect
+ $redis._client.disconnect
end
end
@@ -211,7 +211,7 @@ before_fork do |server, worker|
end
ActiveRecord::Base.connection.disconnect!
- $redis.client.disconnect
+ $redis._client.disconnect
# Throttle the master from forking too quickly by sleeping. Due
# to the implementation of standard Unix signal handlers, this
diff --git a/lib/discourse.rb b/lib/discourse.rb
index f0846277005..0673e1f119f 100644
--- a/lib/discourse.rb
+++ b/lib/discourse.rb
@@ -432,7 +432,7 @@ module Discourse
RailsMultisite::ConnectionManagement.establish_connection(db: current_db)
MessageBus.after_fork
SiteSetting.after_fork
- $redis.client.reconnect
+ $redis._client.reconnect
Rails.cache.reconnect
Logster.store.redis.reconnect
# shuts down all connections in the pool
diff --git a/lib/discourse_redis.rb b/lib/discourse_redis.rb
index 49f0a3ec1d4..800acd4980d 100644
--- a/lib/discourse_redis.rb
+++ b/lib/discourse_redis.rb
@@ -229,7 +229,7 @@ class DiscourseRedis
end
def reconnect
- @redis.client.reconnect
+ @redis._client.reconnect
end
def namespace_key(key)