Permalink
Browse files

cluster: free_connections should be assigned before num_connections @…

…ClusterHandler::startClusterEvent(...)

When cluster member is removed from the cluster, it will trigger a
core when deleting the cluster machine, 2 days later.

Signed-off-by: Zhao Yongming <ming.zym@gmail.com>
  • Loading branch information...
quehan authored and mingzym committed Mar 20, 2013
1 parent 13411cb commit 09b28d447bb266172f4ad6e16a8ebbb17aec74e6
Showing with 1 addition and 1 deletion.
  1. +1 −1 iocore/cluster/ClusterHandlerBase.cc
@@ -1044,8 +1044,8 @@ ClusterHandler::startClusterEvent(int event, Event * e)
if (m->clusterHandlers[i])
m->clusterHandlers[i]->downing = true;
}
- m->num_connections = machine->num_connections;
m->free_connections -= (m->num_connections - machine->num_connections);
+ m->num_connections = machine->num_connections;
// delete_this
failed = -2;
MUTEX_UNTAKE_LOCK(the_cluster_config_mutex, this_ethread());

0 comments on commit 09b28d4

Please sign in to comment.