mirror of https://github.com/citusdata/citus.git
Print notification for each colocated shard.
parent
8afa2d0386
commit
a7580f4443
|
@ -861,15 +861,28 @@ ExecutePlacementUpdates(List *placementUpdateList, Oid shardReplicationModeOid,
|
||||||
foreach(placementUpdateCell, placementUpdateList)
|
foreach(placementUpdateCell, placementUpdateList)
|
||||||
{
|
{
|
||||||
PlacementUpdateEvent *placementUpdate = lfirst(placementUpdateCell);
|
PlacementUpdateEvent *placementUpdate = lfirst(placementUpdateCell);
|
||||||
ereport(NOTICE, (errmsg(
|
List *colocatedUpdateList = GetColocatedRebalanceSteps(list_make1(
|
||||||
"%s shard %lu from %s:%u to %s:%u ...",
|
placementUpdate));
|
||||||
noticeOperation,
|
ListCell *colocatedUpdateCell = NULL;
|
||||||
placementUpdate->shardId,
|
|
||||||
placementUpdate->sourceNode->workerName,
|
/*
|
||||||
placementUpdate->sourceNode->workerPort,
|
* Print the notification for each colocated shard as the placement of each colocated
|
||||||
placementUpdate->targetNode->workerName,
|
* shard will be updated in the subsequent call.
|
||||||
placementUpdate->targetNode->workerPort
|
*/
|
||||||
)));
|
foreach(colocatedUpdateCell, colocatedUpdateList)
|
||||||
|
{
|
||||||
|
PlacementUpdateEvent *colocatedUpdate = lfirst(colocatedUpdateCell);
|
||||||
|
|
||||||
|
ereport(NOTICE, (errmsg(
|
||||||
|
"%s shard %lu from %s:%u to %s:%u ...",
|
||||||
|
noticeOperation,
|
||||||
|
colocatedUpdate->shardId,
|
||||||
|
colocatedUpdate->sourceNode->workerName,
|
||||||
|
colocatedUpdate->sourceNode->workerPort,
|
||||||
|
colocatedUpdate->targetNode->workerName,
|
||||||
|
colocatedUpdate->targetNode->workerPort
|
||||||
|
)));
|
||||||
|
}
|
||||||
UpdateShardPlacement(placementUpdate, responsiveWorkerList,
|
UpdateShardPlacement(placementUpdate, responsiveWorkerList,
|
||||||
shardReplicationModeOid);
|
shardReplicationModeOid);
|
||||||
MemoryContextReset(localContext);
|
MemoryContextReset(localContext);
|
||||||
|
|
|
@ -1776,6 +1776,8 @@ DETAIL: The balance improvement of 0.1xxxxx is lower than the improvement_thres
|
||||||
NOTICE: Ignored 1 moves, all of which are shown in notices above
|
NOTICE: Ignored 1 moves, all of which are shown in notices above
|
||||||
HINT: If you do want these moves to happen, try changing improvement_threshold to a lower value than what it is now (0.5).
|
HINT: If you do want these moves to happen, try changing improvement_threshold to a lower value than what it is now (0.5).
|
||||||
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
rebalance_table_shards
|
rebalance_table_shards
|
||||||
---------------------------------------------------------------------
|
---------------------------------------------------------------------
|
||||||
|
@ -2805,6 +2807,8 @@ select 1 from citus_add_node('localhost', :worker_2_port);
|
||||||
(1 row)
|
(1 row)
|
||||||
|
|
||||||
select rebalance_table_shards();
|
select rebalance_table_shards();
|
||||||
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
rebalance_table_shards
|
rebalance_table_shards
|
||||||
---------------------------------------------------------------------
|
---------------------------------------------------------------------
|
||||||
|
@ -2905,6 +2909,8 @@ SELECT sh.logicalrelid, pl.nodeport
|
||||||
-- but because the coordinator is not allowed for shards, rebalancer will distribute each colocation group to both workers
|
-- but because the coordinator is not allowed for shards, rebalancer will distribute each colocation group to both workers
|
||||||
select rebalance_table_shards(shard_transfer_mode:='block_writes');
|
select rebalance_table_shards(shard_transfer_mode:='block_writes');
|
||||||
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
rebalance_table_shards
|
rebalance_table_shards
|
||||||
---------------------------------------------------------------------
|
---------------------------------------------------------------------
|
||||||
|
|
|
@ -244,6 +244,7 @@ DROP TABLE statement_replicated;
|
||||||
-- and the other in block_writes
|
-- and the other in block_writes
|
||||||
SELECT rebalance_table_shards(max_shard_moves:=1);
|
SELECT rebalance_table_shards(max_shard_moves:=1);
|
||||||
NOTICE: Stopped searching before we were out of moves. Please rerun the rebalancer after it's finished for a more optimal placement.
|
NOTICE: Stopped searching before we were out of moves. Please rerun the rebalancer after it's finished for a more optimal placement.
|
||||||
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
rebalance_table_shards
|
rebalance_table_shards
|
||||||
---------------------------------------------------------------------
|
---------------------------------------------------------------------
|
||||||
|
@ -252,6 +253,8 @@ NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
|
|
||||||
SELECT rebalance_table_shards(shard_transfer_mode:='block_writes');
|
SELECT rebalance_table_shards(shard_transfer_mode:='block_writes');
|
||||||
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
rebalance_table_shards
|
rebalance_table_shards
|
||||||
---------------------------------------------------------------------
|
---------------------------------------------------------------------
|
||||||
|
@ -417,6 +420,9 @@ SET citus.shard_replication_factor TO 1;
|
||||||
SELECT master_drain_node('localhost', :master_port, shard_transfer_mode:='block_writes');
|
SELECT master_drain_node('localhost', :master_port, shard_transfer_mode:='block_writes');
|
||||||
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
|
||||||
master_drain_node
|
master_drain_node
|
||||||
---------------------------------------------------------------------
|
---------------------------------------------------------------------
|
||||||
|
|
Loading…
Reference in New Issue