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

Support new ZADD options introduced at Redis 3.0.2 #1083

Merged

Conversation

HeartSaVioR
Copy link
Contributor

Closes #1067

We discussed many things from #1067, so please refer that issue for more details.

I didn't add javadoc for added methods for some reasons.
I'll address what thing prevents me to add javadoc to #978.

Please review and comment. Thanks!

* Please refer http://redis.io/commands/zadd for more details
* You can see its functionalities from newly added unit tests
* that it requires Redis 3.0.2 and onwards
* also fix formatting
@HeartSaVioR HeartSaVioR added this to the 2.8.0 milestone Aug 5, 2015
@HeartSaVioR HeartSaVioR mentioned this pull request Aug 5, 2015
@jpe42
Copy link

jpe42 commented Aug 6, 2015

Looks great. Thanks for handling all of this, sorry that it had to turn into such a fuss... Looking forward to the *Param args as well.


public void zaddBinary(final byte[] key, final Map<byte[], Double> scoreMembers) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know it has nothing to do with this PR. But I was looking at the zaddBinary method and I was thinking: "why is it called zaddBinary if zadd is already binary?". Then I realized that the difference is that zaddBinary accepts multiple score members.

Maybe we can take the opportunity to rename this method to just zadd?. In Client.java the method that calls zaddBinary is called zadd.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@marcosnils
Great finding! Renamed zaddBinary to zadd.
Maybe it was just a workaround if Java compiler or JVM could not distinguish methods if only param's Generic is different.
For now, all tests passed.

@marcosnils
Copy link
Contributor

@HeartSaVioR PR is perfect. Let's see what we want to do with the zaddBinary thing and then merge :)

@marcosnils
Copy link
Contributor

@HeartSaVioR LAGTM (Looks amazingly good to me??) 👍

@HeartSaVioR
Copy link
Contributor Author

@jamespedwards42 You don't need to be sorry. It was me who can't stand with that decision. :)

Conflicts:
	src/main/java/redis/clients/jedis/JedisCluster.java
HeartSaVioR added a commit that referenced this pull request Aug 7, 2015
Support new ZADD options introduced at Redis 3.0.2
@HeartSaVioR HeartSaVioR merged commit 9e95ce1 into redis:master Aug 7, 2015
@HeartSaVioR
Copy link
Contributor Author

Merged into master and 2.8 branch respectively.
Thanks all!

@HeartSaVioR HeartSaVioR deleted the support-new-zadd-options-3.0.2 branch November 23, 2015 22:05
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.

3 participants