Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

undefined method `set' for an instance of ConnectionPool #185

Open
afuno opened this issue Feb 28, 2024 · 0 comments
Open

undefined method `set' for an instance of ConnectionPool #185

afuno opened this issue Feb 28, 2024 · 0 comments

Comments

@afuno
Copy link

afuno commented Feb 28, 2024

When trying to update the project to Rails 7.1, the following problems began to arise in RSpec:

undefined method `set' for an instance of ConnectionPool

This occurs due to the call to the clear method in cache.clear. And cache in turn has this code:

cache = ActiveSupport::Cache::RedisCacheStore.new(
  redis: CurrentRedis.connection_pool,
  namespace: ...,
  expires_in: ...
)

connection_pool is:

@connection_pool ||= ConnectionPool.new(size: ..., timeout: ...) do
  Redis.new(**redis_args)
end

Please tell me, is this a problem in the configuration on my side or is it a problem in the ConnectionPool, which cannot work correctly in Rails 7.1? If the problem is in the configuration, then tell me how to fix it?

@afuno afuno changed the title undefined method `scan' for an instance of ConnectionPool undefined method `set' for an instance of ConnectionPool Feb 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant