Giter VIP home page Giter VIP logo

ruskit's People

Contributors

damnever avatar doyoubi avatar maralla avatar wooparadog avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ruskit's Issues

加一个timeout选项

现在与redis连接的超时时间都是 1 秒, 之前删除节点的时候可能因为节点数据较多, flushall完成需要几秒, 所以需要给可能耗时较长的命令加个timeout选项.

fix slots bug

由于cluster nodes只会返回当前节点的迁移信息, 而之前又把获取节点信息由从所有节点获取改成只由一个节点获取, 所以现在fix slots是有问题的.

一致性检查可能存在问题

由于对节点做更改操作后, 可能cluster nodes没有立刻反应修改的东西(如之前发现的加了节点后, cluster nodes里面有一瞬间还没改), 导致现在的一致性检查(cluster.wait)可能存在这样的bug:

  1. 对节点做了更改操作
  2. 操作完成后, 所有节点在一瞬间响应的cluster nodes没有更改, 跟之前一样.
  3. wait的consistent检查在这一瞬间通过, 但是再后面的consistent检查中, 某些节点的cluster nodes开始反应有更改了, 这样后续的consistent操作就会不通过.

优化集群状态一致性检查.

现在检查集群状态一致性时, 只检查名字和槽位, 而且只检查了是否缺槽位, 没有检查槽位所属是否一致.
此外, 希望可以查出具体哪一部分不一致, 方便debug集群.

优化均分槽位

现在均分槽位的算法(cluster.py中的slot_balance)在多次执行后会把槽位分得很散, 导致cluster nodescluster slots返回的数据非常大, 因此需要优化均分槽位的算法.
要求:
1 整个集群均分时尽可能少迁移槽位
2 不能迁移包含大量数据的槽位
3 整个集群均分后, 槽位尽可能连续 (集群中被切碎的槽位区间尽可能少)

啥时候发布新的 pypi 啊...

前几天在 FLUSHALL 的时候去尝试连接发现挂了, 因为代码会去 PING, 那个数据库很大, FLUSHALL 要一点时间的. 然后就发现... 为啥仓库里最新的代码没有 PING!!! 一看发现 pypi 上的是 0.0.7, github 都 0.0.22 了... 😿 啥时候发布个更新啊... 感恩各位爸爸...

环境问题

[root@sh-redis-01 env]# ruskit -h
Traceback (most recent call last):
File "/www/env/python27/bin/ruskit", line 5, in
from pkg_resources import load_entry_point
File "/www/env/python27/lib/python2.7/site-packages/distribute-0.6.14-py2.7.egg/pkg_resources.py", line 2671, in
working_set.require(requires)
File "/www/env/python27/lib/python2.7/site-packages/distribute-0.6.14-py2.7.egg/pkg_resources.py", line 654, in require
needed = self.resolve(parse_requirements(requirements))
File "/www/env/python27/lib/python2.7/site-packages/distribute-0.6.14-py2.7.egg/pkg_resources.py", line 552, in resolve
raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: redis>=2.10.5

[root@sh-redis-01 env]# pip list
bson (0.4.6)
distribute (0.6.14)
elasticsearch (2.4.0)
funcsigs (1.0.2)
hiredis (0.2.0)
mock (2.0.0)
MySQL-python (1.2.5)
mysql-replication (0.11)
pbr (1.10.0)
pip (7.1.2)
pymongo (3.4.0)
PyMySQL (0.7.10)
pytz (2016.10)
redis (2.10.5)
requests (2.11.1)
ruskit (0.0.23)
setuptools (0.6rc11)
six (1.10.0)
urllib3 (1.17)

减慢添加从节点的速度

现在addslave命令会一次性加入所有从节点, 然后等待集群一致. 这在添加大量节点的时候会导致大量主从全同步.
因此需要减慢添加节点的速度, 最好能够等待一批节点完成同步数据, 再加入另一批从节点.

检查slave分配是否合理

加个检查命令, 可以查

  1. slave是否跟master在同一台机器上
  2. 一台机器是否有多个slave跟随同一个master
  3. 一个集群中是否一半或以上的主节点在一台机器上

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.