[sheepdog] [PATCH v6 0/6] Improving zookeeper driver
Kai Zhang
kyle at zelin.io
Fri Jun 21 14:34:38 CEST 2013
v6:
- add a lock to protect zk_compete_master() function
- make sure session timeout event will be safe and not trigger panic()
- use _kill_sheep() other than raw pkill in tests
- add copyright to tools/kill_zk_session.c
- rebase to upstream
v5:
- fixed error of hang on joining cluster
- update commit log
- add tests/functional/066 to reproduce concurrent start up error of old
implementation
v4:
- fixed compile errors
- update check_zk_rc() to handle ZOPERATIONTIMEOUT and ZCONNECTIONLOSS
- rebase to upstream
v3:
- add another patch for handling session timeout of on the fly zookeeper
operations
v2:
- fixed error of hang on joining cluster
Current zookeeper driver is fragile during bad network enviroment.
This series is to improve the robustness of zookeeper driver in fowlling ways:
- fix failure when multiple sheep join cluster concurrently
- re-join cluster when zookeeper session timeout
- handle ZINVALIDSTATE, don't call panic() simplely
Kai Zhang (6):
zookeeper: fixed concurrent startup error
tests/functional: add 067 for testing concurrent start up
sheep: rejoin cluster after a zookeeper session timeout
tools: add kill_zk_session
tests/functional: add 068 for testing rejoin cluster
zookeeper: handle session timeout for all zookeeper operations
Makefile.am | 2 +-
configure.ac | 3 +-
sheep/cluster.h | 1 +
sheep/cluster/zookeeper.c | 525 ++++++++++++++++++++++++++++++++++----------
sheep/group.c | 12 +
tests/functional/067 | 49 +++++
tests/functional/067.out | 13 ++
tests/functional/068 | 46 ++++
tests/functional/068.out | 38 ++++
tests/functional/common.rc | 15 ++
tests/functional/group | 2 +
tools/Makefile.am | 13 ++
tools/kill_zk_session.c | 71 ++++++
13 files changed, 673 insertions(+), 117 deletions(-)
create mode 100755 tests/functional/067
create mode 100644 tests/functional/067.out
create mode 100755 tests/functional/068
create mode 100644 tests/functional/068.out
create mode 100644 tools/Makefile.am
create mode 100644 tools/kill_zk_session.c
--
1.7.9.5
More information about the sheepdog
mailing list