diff options
author | Jacob Vosmaer <jacob@gitlab.com> | 2016-09-30 13:27:43 +0300 |
---|---|---|
committer | Jacob Vosmaer <jacob@gitlab.com> | 2016-09-30 13:27:43 +0300 |
commit | 52ee85e7bf35d372285d70cc93016854774839b1 (patch) | |
tree | b18aa064138d2762834c267f20dd4d295660983f /config/initializers/7_redis.rb | |
parent | 7d48778c4f35e61fd3e6e9bfbb476c27f9fb4602 (diff) |
Initialize Redis pool in single-threaded context
This side-steps the need for mutexes and whatnot.
Diffstat (limited to 'config/initializers/7_redis.rb')
-rw-r--r-- | config/initializers/7_redis.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/config/initializers/7_redis.rb b/config/initializers/7_redis.rb new file mode 100644 index 00000000000..ae2ca258df1 --- /dev/null +++ b/config/initializers/7_redis.rb @@ -0,0 +1,3 @@ +# Make sure we initialize a Redis connection pool before Sidekiq starts +# multi-threaded execution. +Gitlab::Redis.with { nil } |