-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Multi exec on cluster #3611
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
Multi exec on cluster #3611
Conversation
dee69d2
to
9937904
Compare
@elena-kolevska this needs workflow approval, thanks |
Adds support for transactions based on multi/watch/exec on clusters. Transactions in this mode are limited to a single hash slot. Contributed-by: Scopely <[email protected]>
9937904
to
f9cc550
Compare
…scopely/redis-py into multi-exec-on-cluster
…scopely/redis-py into multi-exec-on-cluster
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.
Pull Request Overview
This PR adds support for transactions in cluster clients using multi/watch/exec commands (with the same slot limitation as standalone clients) and updates tests, documentation, and exception handling accordingly. Key changes include new tests for cluster transaction behaviors, additions to exception classes to better indicate transaction errors, and updated documentation reflecting the new transaction support in clusters.
Reviewed Changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 1 comment.
Show a summary per file
File | Description |
---|---|
tests/test_cluster_transaction.py | Adds tests to validate transaction support in cluster mode. |
tests/test_cluster.py | Updates tests for pipeline behavior and multi delete operations. |
redis/exceptions.py | Introduces new exceptions (CrossSlotTransactionError, InvalidPipelineStack). |
redis/client.py | Updates Pipeline constructor with type annotations and minor refactoring. |
docs/advanced_features.rst | Updates documentation to describe transaction handling in clusters. |
CHANGES | Records support for transactions in ClusterPipeline. |
.github/wordlist.txt | Adds CAS to the wordlist. |
…scopely/redis-py into multi-exec-on-cluster
@robertosantamaria-scopely Hey! I would appreciate your review, since the PR was refactored |
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.
LGTM.
Thanks @vladvildanov ; I can't give a ✅ as the PR is on my name, but you have my 👍 for sure. Cheers! |
@robertosantamaria-scopely Thanks! |
Pull Request check-list
Please make sure to review and check all of these items:
NOTE: these things are not required to open a PR and can be done
afterwards / while the PR is open.
Description of change
This adds support for transactions in cluster clients. These transactions are based on multi/watch/exec, same as for standalone client, but are limited to a single hash slot.