[sheepdog] [PATCH 0/2] A better way to remove queue nodes

Meng Lingkun starmlk at 163.com
Mon Mar 9 05:55:48 CET 2015

From: Meng Lingkun <menglingkun at cmss.chinamobile.com>

Zookeeper cluster driver can't and doesn't delete the znode in queue
after using it. It makes zookeeper occupy much more memory. And it makes
troubles when zookeeper client reconnects to zookeeper server.
reference: https://issues.apache.org/jira/browse/ZOOKEEPER-706
Subcommand delete provides a better way than purge subcommand:
1. sheep update it's queue_pos to zookeeper server;
2. zk_control find the minimum of all sheeps' queue_pos, and removes
   znodes seq < minimum;
3. zk_control can run in crond to limit the queue znode.

Meng Lingkun (2):
  zookeeper: update queue_pos to zookeeper-server
  tools/zk_control: add detele subcommand to remove queue nodes

 sheep/cluster/zookeeper.c | 32 +++++++++++++++++
 tools/zk_control.c        | 88 ++++++++++++++++++++++++++++++++++++++++++++++-
 2 files changed, 119 insertions(+), 1 deletion(-)


More information about the sheepdog mailing list