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

name property for RedisServer #146

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

redlion99
Copy link

Add name property for RedisServer, so it's possible to add multi connection in the pool for a single server.

Add name property for RedisServer, so it's possible to add multi connection in the pool for a single server.
@coveralls
Copy link

coveralls commented Jul 11, 2016

Coverage Status

Coverage remained the same at 92.502% when pulling 4ab3d23 on redlion99:master into f1c1101 on etaty:master.

@etaty
Copy link
Owner

etaty commented Jul 11, 2016

Thanks
Could you post a gist to help me understand the use case?

@redlion99
Copy link
Author

redlion99 commented Jul 11, 2016

Sometimes we need to create more than one connection for a single server. without the name property if we setup a pool like

RedisClientPool( RedisServer("localhost"), RedisServer("localhost"))

We just get one active connection in the pool, because the case class in the key of the connection map has the same hashcode.

if we have a name property it works like this:

RedisClientPool( RedisServer("localhost", name = "a"), RedisServer("localhost", name = "b"))

@etaty etaty force-pushed the master branch 2 times, most recently from 3c1bce9 to ffd4f94 Compare November 20, 2016 12:12
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

Successfully merging this pull request may close these issues.

None yet

3 participants