mirror of https://github.com/citusdata/citus.git
Remove hint message from master_remove_node UDF
Hint about master_disable_node was giving wrong impression to users. Removal is better than keeping it.pull/1143/head
parent
c0f1a7609f
commit
c12bd7b75e
|
@ -411,8 +411,7 @@ RemoveNodeFromCluster(char *nodeName, int32 nodePort, bool forceRemove)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
ereport(ERROR, (errmsg("you cannot remove a node which has active "
|
ereport(ERROR, (errmsg("you cannot remove a node which has active "
|
||||||
"shard placements"),
|
"shard placements")));
|
||||||
errhint("Consider using master_disable_node.")));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -113,7 +113,6 @@ SELECT shardid, shardstate, nodename, nodeport FROM pg_dist_shard_placement WHER
|
||||||
-- try to remove a node with active placements and see that node removal is failed
|
-- try to remove a node with active placements and see that node removal is failed
|
||||||
SELECT master_remove_node('localhost', :worker_2_port);
|
SELECT master_remove_node('localhost', :worker_2_port);
|
||||||
ERROR: you cannot remove a node which has active shard placements
|
ERROR: you cannot remove a node which has active shard placements
|
||||||
HINT: Consider using master_disable_node.
|
|
||||||
SELECT master_get_active_worker_nodes();
|
SELECT master_get_active_worker_nodes();
|
||||||
master_get_active_worker_nodes
|
master_get_active_worker_nodes
|
||||||
--------------------------------
|
--------------------------------
|
||||||
|
@ -148,7 +147,6 @@ SELECT master_add_node('localhost', :worker_2_port);
|
||||||
-- try to remove a node with active placements and see that node removal is failed
|
-- try to remove a node with active placements and see that node removal is failed
|
||||||
SELECT master_remove_node('localhost', :worker_2_port);
|
SELECT master_remove_node('localhost', :worker_2_port);
|
||||||
ERROR: you cannot remove a node which has active shard placements
|
ERROR: you cannot remove a node which has active shard placements
|
||||||
HINT: Consider using master_disable_node.
|
|
||||||
-- mark all placements in the candidate node as inactive
|
-- mark all placements in the candidate node as inactive
|
||||||
UPDATE pg_dist_shard_placement SET shardstate=3 WHERE nodeport=:worker_2_port;
|
UPDATE pg_dist_shard_placement SET shardstate=3 WHERE nodeport=:worker_2_port;
|
||||||
SELECT shardid, shardstate, nodename, nodeport FROM pg_dist_shard_placement WHERE nodeport=:worker_2_port;
|
SELECT shardid, shardstate, nodename, nodeport FROM pg_dist_shard_placement WHERE nodeport=:worker_2_port;
|
||||||
|
|
Loading…
Reference in New Issue