Sha256: 7b65c5b727e338ae6c097e2e77aef19abf68e32dab4f3f15bccfb1af8e834636

Contents?: true

Size: 403 Bytes

Versions: 18

Compression:

Stored size: 403 Bytes

Contents

# frozen_string_literal: true
require 'redis'
require 'connection_pool'
config = YAML.safe_load(ERB.new(IO.read(Rails.root.join('config', 'redis.yml'))).result)[Rails.env].with_indifferent_access

size = ENV.fetch("HYRAX_REDIS_POOL_SIZE", 5)
timeout = ENV.fetch("HYRAX_REDIS_TIMEOUT", 5)

Hyrax.config.redis_connection =
  ConnectionPool::Wrapper.new(size: size, timeout: timeout) { Redis.new(config) }

Version data entries

18 entries across 6 versions & 1 rubygems

Version Path
hyrax-5.0.1 .dassie/config/initializers/redis_config.rb
hyrax-5.0.1 lib/generators/hyrax/templates/config/initializers/redis_config.rb
hyrax-5.0.1 .koppie/config/initializers/redis_config.rb
hyrax-5.0.0 .dassie/config/initializers/redis_config.rb
hyrax-5.0.0 .koppie/config/initializers/redis_config.rb
hyrax-5.0.0 lib/generators/hyrax/templates/config/initializers/redis_config.rb
hyrax-5.0.0.rc3 .koppie/config/initializers/redis_config.rb
hyrax-5.0.0.rc3 lib/generators/hyrax/templates/config/initializers/redis_config.rb
hyrax-5.0.0.rc3 .dassie/config/initializers/redis_config.rb
hyrax-5.0.0.rc2 .dassie/config/initializers/redis_config.rb
hyrax-5.0.0.rc2 .koppie/config/initializers/redis_config.rb
hyrax-5.0.0.rc2 lib/generators/hyrax/templates/config/initializers/redis_config.rb
hyrax-5.0.0.rc1 lib/generators/hyrax/templates/config/initializers/redis_config.rb
hyrax-5.0.0.rc1 .koppie/config/initializers/redis_config.rb
hyrax-5.0.0.rc1 .dassie/config/initializers/redis_config.rb
hyrax-4.0.0 .dassie/config/initializers/redis_config.rb
hyrax-4.0.0 lib/generators/hyrax/templates/config/initializers/redis_config.rb
hyrax-4.0.0 .koppie/config/initializers/redis_config.rb