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

Cluster pipelining #1455

Open
wants to merge 9 commits into
base: master
Choose a base branch
from
Open

Cluster pipelining #1455

wants to merge 9 commits into from

Conversation

sdncha
Copy link

@sdncha sdncha commented Jan 2, 2017

Added pipelining support to JedisCluster, making least changes on other classes. The idea is capturing all commands sent with pipeline, and replaying them for cluster redirecting.

@marcosnils
Copy link
Contributor

@sdncha thx for the contribution!. This PR looks promising and hopefully we can merge soon. It'll probably take me some time but I definitely would like to include it. @HeartSaVioR if you have some time I'd like your help to review.

@sdncha
Copy link
Author

sdncha commented Jan 2, 2017

@marcosnils , glad to hear that. I look forward to your reviews and would like to improve it, make it good enough to be merged.

@HeartSaVioR
Copy link
Contributor

@sdncha
Thanks for the contribution. Could you refer the latest comments on #1527 to see my theory on this side, and put your theory?
Please note that only idempotent operations could be placed to replay.

@HeartSaVioR
Copy link
Contributor

You may want to revisit the discussion prior to put your theory: https://groups.google.com/d/msg/redis-db/4I0ELYnf3bk/Lrctk0ULm6AJ

@ChetanBhasin
Copy link

I was wondering what the status of this PR is. Is anyone still looking at it?

@rkass
Copy link

rkass commented Oct 23, 2018

Any updates on this?

@ucjonathan
Copy link

+1 for support for pipelining on a cluster. Would like to continue using Jedis libraries to talk to Elasticache without having to rewrite a bunch of existing code since pipelining is not supported. Pipelining is apparently is supported by the lettuce.io library, but rewriting everything is even less appealing.

@mpermar
Copy link

mpermar commented Nov 9, 2018

This would be a real nice feature.

@saberem
Copy link

saberem commented Jan 24, 2019

@marcosnils @sdncha @HeartSaVioR Any further discussion on this given the latest comments on #1527?

@Unknow0
Copy link

Unknow0 commented Jul 22, 2019

Hi @sdncha,

when we had a network issue we had a lot of unclosed connection plus we had a lot of these exception:

redis.clients.jedis.exceptions.JedisException: Could not return the resource to the pool
    at redis.clients.jedis.JedisPool.returnResource(JedisPool.java:247)
    at redis.clients.jedis.Jedis.close(Jedis.java:3449)
    at redis.clients.jedis.JedisClusterPipeline.releaseConnection(JedisClusterPipeline.java:278)
    at redis.clients.jedis.JedisClusterPipeline.reset(JedisClusterPipeline.java:288)
    at redis.clients.jedis.JedisClusterPipeline.sync(JedisClusterPipeline.java:314)
    at redis.clients.jedis.JedisClusterPipeline.syncAndReturnAll(JedisClusterPipeline.java:330)
// [..]
Caused by: redis.clients.jedis.exceptions.JedisException: Could not return the resource to the pool
    at redis.clients.util.Pool.returnResourceObject(Pool.java:64)
    at redis.clients.jedis.JedisPool.returnResource(JedisPool.java:244)
    ... 12 more
Caused by: java.lang.IllegalStateException: Object has already been returned to this pool or is invalid
    at org.apache.commons.pool2.impl.GenericObjectPool.returnObject(GenericObjectPool.java:551)
    at redis.clients.util.Pool.returnResourceObject(Pool.java:62)
    ... 13 more

i didn't at time to look more into it :s

Regards.

@lcy362
Copy link

lcy362 commented Dec 21, 2019

Any update?

@ucjonathan
Copy link

I'd also like to see cluster pipelining as well. Tons of older code that we would have to re-write just to move to newer cluster deployment of redis. Can we move past the religious debate about whether there should be pipelining and add support for it? Have it off by default if you like.

@funaiy
Copy link

funaiy commented Dec 24, 2019

Any update?

@jaronoff97
Copy link

Any updates? It's been more than three years now 😅

@ucjonathan
Copy link

I just bit the bullet and refactored the code to use JedisCluster and stop pipelining. It actually wasn't as bad as I had expected it to be.

@marcosnils
Copy link
Contributor

I just bit the bullet and refactored the code to use JedisCluster and stop pipelining. It actually wasn't as bad as I had expected it to be.

:D

akshay-gavagai added a commit to gavagai-corp/jedis that referenced this pull request Nov 17, 2020
@esigma5
Copy link

esigma5 commented Jan 26, 2023

Any update? Argentina won their third football world cup but this PR is still not merged 🙏

@sazzad16
Copy link
Collaborator

@esigma5 Give it at least 36 years.

Enjoy ClusterPipeline for now.

public class ClusterPipeline extends MultiNodePipelineBase {

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.