-
Notifications
You must be signed in to change notification settings - Fork 0
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
Java: Add command BITCOUNT
#263
Conversation
Signed-off-by: Guian Gumpac <guian.gumpac@improving.com>
Signed-off-by: Guian Gumpac <guian.gumpac@improving.com>
java/client/src/main/java/glide/api/commands/BitmapBaseCommands.java
Outdated
Show resolved
Hide resolved
java/client/src/main/java/glide/api/commands/BitmapBaseCommands.java
Outdated
Show resolved
Hide resolved
java/client/src/main/java/glide/api/models/BaseTransaction.java
Outdated
Show resolved
Hide resolved
java/client/src/main/java/glide/api/models/BaseTransaction.java
Outdated
Show resolved
Hide resolved
java/client/src/main/java/glide/api/models/BaseTransaction.java
Outdated
Show resolved
Hide resolved
java/client/src/main/java/glide/api/models/BaseTransaction.java
Outdated
Show resolved
Hide resolved
java/client/src/main/java/glide/api/models/commands/BitcountOptions.java
Outdated
Show resolved
Hide resolved
java/client/src/main/java/glide/api/models/commands/BitcountOptions.java
Outdated
Show resolved
Hide resolved
java/integTest/src/test/java/glide/TransactionTestUtilities.java
Outdated
Show resolved
Hide resolved
java/client/src/main/java/glide/api/commands/BitmapBaseCommands.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Guian Gumpac <guian.gumpac@improving.com>
java/client/src/main/java/glide/api/commands/BitmapBaseCommands.java
Outdated
Show resolved
Hide resolved
java/client/src/main/java/glide/api/commands/BitmapBaseCommands.java
Outdated
Show resolved
Hide resolved
java/client/src/main/java/glide/api/models/commands/BitcountOptions.java
Outdated
Show resolved
Hide resolved
java/client/src/main/java/glide/api/models/commands/BitcountOptions.java
Outdated
Show resolved
Hide resolved
java/client/src/main/java/glide/api/models/BaseTransaction.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please fix tests
Signed-off-by: Guian Gumpac <guian.gumpac@improving.com>
* | ||
* @see <a href="https://redis.io/commands/bitcount/">redis.io</a> | ||
*/ | ||
@RequiredArgsConstructor |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can remove constructor too
@@ -178,6 +179,10 @@ public static BaseTransaction<?> transactionTest(BaseTransaction<?> baseTransact | |||
.pfmerge(hllKey3, new String[] {hllKey1, hllKey2}) | |||
.pfcount(new String[] {hllKey3}); | |||
|
|||
baseTransaction.bitcount(key3); | |||
baseTransaction.bitcount(key3, 2, 4); | |||
baseTransaction.bitcount(key3, 2, 19, BitMapOptions.BIT); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this test - it fails on redis 6.
It is ok to omit it, but if you want to test this in transaction - create a separate test cases for cluster and standalone client. Or wait for valkey-io#1284.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As discussed, it's better to wait for valkey-io#1284. Will add to PR to ignore GHA failures.
Signed-off-by: Guian Gumpac <guian.gumpac@improving.com>
* Implemented Bitcount command for java client Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Removed unrelated change Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Addressed PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Addressed PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Removed unnecessary constructor Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> --------- Signed-off-by: Guian Gumpac <guian.gumpac@improving.com>
* Implemented Bitcount command for java client Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Removed unrelated change Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Addressed PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Addressed PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Removed unnecessary constructor Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> --------- Signed-off-by: Guian Gumpac <guian.gumpac@improving.com>
* Java: Add command `BITCOUNT` (#263) * Implemented Bitcount command for java client Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Removed unrelated change Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Addressed PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Addressed PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Removed unnecessary constructor Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> --------- Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Resolved conflicts Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Renamed interface for consistency Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Address PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Added missed javadoc Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Addressed comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Update java/client/src/main/java/glide/api/commands/BitmapBaseCommands.java Co-authored-by: Aaron <69273634+aaron-congo@users.noreply.github.com> * Update java/client/src/main/java/glide/api/commands/BitmapBaseCommands.java Co-authored-by: Aaron <69273634+aaron-congo@users.noreply.github.com> * addressed PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Addressed PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Removed wrong version check Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Rebased and resolved conflicts Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> --------- Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> Co-authored-by: Aaron <69273634+aaron-congo@users.noreply.github.com>
* Java: Add command `BITCOUNT` (#263) * Implemented Bitcount command for java client Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Removed unrelated change Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Addressed PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Addressed PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Removed unnecessary constructor Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> --------- Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Resolved conflicts Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Renamed interface for consistency Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Address PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Added missed javadoc Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Addressed comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Update java/client/src/main/java/glide/api/commands/BitmapBaseCommands.java Co-authored-by: Aaron <69273634+aaron-congo@users.noreply.github.com> * Update java/client/src/main/java/glide/api/commands/BitmapBaseCommands.java Co-authored-by: Aaron <69273634+aaron-congo@users.noreply.github.com> * addressed PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Addressed PR comments Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Removed wrong version check Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> * Rebased and resolved conflicts Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> --------- Signed-off-by: Guian Gumpac <guian.gumpac@improving.com> Co-authored-by: Aaron <69273634+aaron-congo@users.noreply.github.com>
Implement https://redis.io/docs/latest/commands/bitcount/ in the java client.