Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
4abf486c
Commit
4abf486c
authored
Jan 22, 2016
by
antirez
Browse files
Cluster announce port: set port/bport for myself at startup.
parent
1c038379
Changes
1
Show whitespace changes
Inline
Side-by-side
src/cluster.c
View file @
4abf486c
...
...
@@ -474,9 +474,14 @@ void clusterInit(void) {
/* The slots -> keys map is a sorted set. Init it. */
server.cluster->slots_to_keys = zslCreate();
/* Set myself->port to my listening port, we'll just need to
discover
* the IP address via MEET messages. */
/* Set myself->port
/ cport
to my listening port
s
, we'll just need to
*
discover
the IP address via MEET messages. */
myself->port = server.port;
myself->cport = server.port+CLUSTER_PORT_INCR;
if (server.cluster_announce_port)
myself->port = server.cluster_announce_port;
if (server.cluster_announce_bus_port)
myself->cport = server.cluster_announce_bus_port;
server.cluster->mf_end = 0;
resetManualFailover();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment