mirror of https://github.com/citusdata/citus.git
Merge pull request #3382 from citusdata/fix-error-on-repeated-placement-done
PlacementExecutionDone: We may mark placements as failed multiple timespull/3387/head
commit
f6d4df6da9
|
@ -3491,6 +3491,15 @@ PlacementExecutionDone(TaskPlacementExecution *placementExecution, bool succeede
|
|||
TaskExecutionState executionState = shardCommandExecution->executionState;
|
||||
bool failedPlacementExecutionIsOnPendingQueue = false;
|
||||
|
||||
if (placementExecution->executionState == PLACEMENT_EXECUTION_FAILED)
|
||||
{
|
||||
/*
|
||||
* We may mark placements as failed multiple times, but should only act
|
||||
* the first time. Nor should we accept success after failure.
|
||||
*/
|
||||
return;
|
||||
}
|
||||
|
||||
/* mark the placement execution as finished */
|
||||
if (succeeded)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue