-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
Warm the internalPool upon initialization of the JedisPool #1828
Comments
tmack8001
changed the title
Upon Initialization of the JedisPool the pool isn't warmed
Warm the internalPool upon initialization of the JedisPool
Jul 6, 2018
@tmack8001 You are welcome to craft a PR, preferably with proper tests. |
@sazzad16 I have a change locally that seems to do what I intend and will offer up a PR by EOW |
tmack8001
added a commit
to tmack8001/jedis
that referenced
this issue
Sep 18, 2019
gkorland
added a commit
to tmack8001/jedis
that referenced
this issue
Dec 3, 2020
gkorland
added a commit
to tmack8001/jedis
that referenced
this issue
Dec 28, 2020
gkorland
added a commit
to tmack8001/jedis
that referenced
this issue
Jun 10, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Expected behavior
I'd expect the behavior of creating a GenericConnectionPool to also warm the connection pool based on the configuration of the pool itself (minIdle, etc). This would take place by calling the following method upon initialization of the connection pool:
This method internally will attempt to ensure that the correct minIdle instances are available for threads to consume and use at the point the pool is first configured. One approach could be to make this optional via a specific pool parameter/argument to say "warmPool: true | false"
Actual behavior
The GenericObjectPool is created with the correct pool configurations, but the pool is never warmed. The logic within GenericObjectPool itself doesn't warm the pool itself upon creation this is up to the user of the object pool instance to maintain.
Steps to reproduce:
Redis / Jedis Configuration
Jedis version: master or 2.9.0 (latest released version)
Redis version: N/A
Java version: N/A
The text was updated successfully, but these errors were encountered: