提交 1793752d 编写于 作者: A antirez

node cluster configuration file configurable via redis.conf

上级 2bc52b2c
......@@ -13,6 +13,7 @@ int clusterNodeGetSlotBit(clusterNode *n, int slot);
sds clusterGenNodesDescription(void);
clusterNode *clusterLookupNode(char *name);
int clusterNodeAddSlave(clusterNode *master, clusterNode *slave);
int clusterAddSlot(clusterNode *n, int slot);
/* -----------------------------------------------------------------------------
* Initialization
......
......@@ -289,6 +289,9 @@ void loadServerConfig(char *filename) {
if ((server.cluster_enabled = yesnotoi(argv[1])) == -1) {
err = "argument must be 'yes' or 'no'"; goto loaderr;
}
} else if (!strcasecmp(argv[0],"cluster-config-file") && argc == 2) {
zfree(server.cluster.configfile);
server.cluster.configfile = zstrdup(argv[1]);
} else {
err = "Bad directive or wrong number of arguments"; goto loaderr;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册