Skip to content
This repository has been archived by the owner on Jan 9, 2024. It is now read-only.

Commit

Permalink
Merge branch 'unstable'
Browse files Browse the repository at this point in the history
  • Loading branch information
Grokzen committed Sep 11, 2016
2 parents 7e5c470 + 263ed1e commit e0b2f53
Show file tree
Hide file tree
Showing 20 changed files with 253 additions and 317 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ install:
- pip install -e .
- "if [[ $HIREDIS == '1' ]]; then pip install hiredis; fi"
env:
# Redis 3.0.6
# Redis 3.0.7
- HIREDIS=0 REDIS_VERSION=3.0
# Redis 3.0.6 and HIREDIS
# Redis 3.0.7 and HIREDIS
- HIREDIS=1 REDIS_VERSION=3.0
# Redis 3.2.0-rc3
- HIREDIS=0 REDIS_VERSION=3.2
Expand Down
8 changes: 6 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ This client provides a client for redis cluster that was added in redis 3.0.

This project is a port of `redis-rb-cluster` by antirez, with alot of added functionality. The original source can be found at https://github.com/antirez/redis-rb-cluster

[![Build Status](https://travis-ci.org/Grokzen/redis-py-cluster.svg?branch=master)](https://travis-ci.org/Grokzen/redis-py-cluster) [![Coverage Status](https://coveralls.io/repos/Grokzen/redis-py-cluster/badge.png)](https://coveralls.io/r/Grokzen/redis-py-cluster) [![PyPI version](https://badge.fury.io/py/redis-py-cluster.svg)](http://badge.fury.io/py/redis-py-cluster) [![Code Health](https://landscape.io/github/Grokzen/redis-py-cluster/unstable/landscape.svg)](https://landscape.io/github/Grokzen/redis-py-cluster/unstable)
Gitter chat room: [![Gitter](https://badges.gitter.im/Grokzen/redis-py-cluster.svg)](https://gitter.im/Grokzen/redis-py-cluster?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)

[![Build Status](https://travis-ci.org/Grokzen/redis-py-cluster.svg?branch=master)](https://travis-ci.org/Grokzen/redis-py-cluster) [![Coverage Status](https://coveralls.io/repos/Grokzen/redis-py-cluster/badge.png)](https://coveralls.io/r/Grokzen/redis-py-cluster) [![PyPI version](https://badge.fury.io/py/redis-py-cluster.svg)](http://badge.fury.io/py/redis-py-cluster)



Expand All @@ -14,7 +16,9 @@ All documentation can be found at http://redis-py-cluster.readthedocs.org/en/mas

This Readme contains a reduced version of the full documentation.

Upgrading instructions between each released version can be found [docs/upgrading.rst](Here)
Upgrading instructions between each released version can be found [here](docs/upgrading.rst)

Changelog for next release and all older releasess can be found [here](docs/release-notes.rst)



Expand Down
4 changes: 2 additions & 2 deletions dev-requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ mock>=1.3.0,<2.0.0
docopt>=0.6.2,<1.0.0
tox>=2.2.0,<3.0.0
python-coveralls>=2.5.0,<3.0.0
ptpdb==0.16
ptpython==0.31
ptpdb>=0.16,<1.0
ptpython>=0.31,<1.0
1 change: 1 addition & 0 deletions docs/authors.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,4 @@ Authors who contributed code or testing:
- etng - https://github.com/etng
- gmolight - https://github.com/gmolight
- baranbartu - https://github.com/baranbartu
- monklof - https://github.com/monklof
52 changes: 0 additions & 52 deletions docs/cluster-mgt.rst

This file was deleted.

23 changes: 22 additions & 1 deletion docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,28 @@ Experimental:



Regarding duplicate pypi and python naming
------------------------------------------

It has been found that the python module name that is used in this library (rediscluster) is already shared with a similar but older project.

This lib will not change the naming of the module to something else to prevent collisions between the libs.

My reasoning for this is the following

- Changing the namespace is a major task and probably should only be done in a complete rewrite of the lib, or if the lib had plans for a version 2.0.0 where this kind of backwards incompatibility could be introduced.
- This project is more up to date, the last merged PR in the other project was 3 years ago.
- This project is aimed for implement support for the cluster support in 3.0+, the other lib do not have that right now, but they implement almost the same cluster solution as the 3.0+ but in much more in the client side.
- The 2 libs is not compatible to be run at the same time even if the name would not collide. It is not recommended to run both in the same python interpreter.

An issue has been raised in each repository to have tracking of the problem.

redis-py-cluster: https://github.com/Grokzen/redis-py-cluster/issues/150

rediscluster: https://github.com/salimane/rediscluster-py/issues/11



The Usage Guide
---------------

Expand All @@ -92,7 +114,6 @@ The Usage Guide
:maxdepth: 2
:glob:

cluster-mgt
commands
limitations-and-differences
pipelines
Expand Down
20 changes: 20 additions & 0 deletions docs/release-notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,26 @@ Release Notes
=============


1.3.0 (Sep 11, 2016)
--------------------

* Removed RedisClusterMgt class and file
* Fixed a bug when using pipelines with RedisCluster class (Ozahata)
* Bump redis-server during travis tests to 3.0.7
* Added docs about same module name in another python redis cluster project.
* Fix a bug when a connection was to be tracked for a node but the node either do not yet exists or
was removed because of resharding was done in another thread. (ashishbaghudana)
* Fixed a bug with "CLUSTER ..." commands when a node_id argument was needed and the return type
was supposed to be converted to bool with bool_ok in redis._compat.
* Add back gitter chat room link
* Add new client commands
- cluster_reset_all_nodes
* Command cluster_delslots now determines what cluster shard each slot is on and sends each slot deletion
command to the correct node. Command have changed argument spec (Read Upgrading.rst for details)
* Fixed a bug when hashing the key it if was a python 3 byte string and it would cause it to route to wrong slot in the cluster (fossilet, Grokzen)
* Fixed a bug when reinitialize the nodemanager it would use the old nodes_cache instead of the new one that was just parsed (monklof)


1.2.0 (Apr 09, 2016)
--------------------

Expand Down
6 changes: 5 additions & 1 deletion docs/upgrading.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,11 @@ This document describes what must be done when upgrading between different versi
1.2.0 --> Next release
----------------------

Class RedisClusterMgt will be removed.
Class RedisClusterMgt has been removed. You should use the `CLUSTER ...` methods that exists in the `StrictRedisCluster` client class.

Method `cluster_delslots` changed argument specification from `self, node_id, *slots` to `self, *slots` and changed the behaviour of the method to now automatically determine the slot_id based on the current cluster structure and where each slot that you want to delete is loated.

Method pfcount no longer has custom logic and exceptions to prevent CROSSSLOT errors. If method is used with different slots then a regular CROSSSLOT error (rediscluster.exceptions.ClusterCrossSlotError) will be returned.



Expand Down
3 changes: 1 addition & 2 deletions rediscluster/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

# Import shortcut
from .client import StrictRedisCluster, RedisCluster
from .cluster_mgt import RedisClusterMgt # NOQA
from .pipeline import StrictClusterPipeline
from .pubsub import ClusterPubSub

Expand All @@ -17,7 +16,7 @@
setattr(redis, "StrictClusterPipeline", StrictClusterPipeline)

# Major, Minor, Fix version
__version__ = (1, 2, 0)
__version__ = (1, 3, 0)

if sys.version_info[0:3] == (3, 4, 0):
raise RuntimeError("CRITICAL: rediscluster do not work with python 3.4.0. Please use 3.4.1 or higher.")
Loading

0 comments on commit e0b2f53

Please sign in to comment.