Stop-ServiceFabricRepairTask
Cancels a repair task.
Syntax
Stop-ServiceFabricRepairTask
[-TaskId] <String>
[[-Version] <Int64>]
[-TimeoutSec <Int32>]
[<CommonParameters>]
Description
The Stop-ServiceFabricRepairTask cmdlet attempts to cancel a Service Fabric repair task. You can cancel only active repair tasks. If this cmdlet succeeds, the request for cancellation is recorded, but the repair task might still be active. Cancellation is best-effort. It requires cooperation of the repair executor once the task has been approved. After you request cancellation, you can monitor the repair task to wait for it to reach the completed state.
This cmdlet supports the Service Fabric platform. Do not run this cmdlet directly.
This cmdlet requires that you connect to the cluster with credentials that are granted administrator access to the cluster. Before you perform any operation on a Service Fabric cluster, establish a connection to the cluster by using the Connect-ServiceFabricCluster cmdlet.
Examples
Example 1: Cancel a repair task
PS C:\> Stop-ServiceFabricRepairTask -TaskId "MyRepairTaskId"
This command requests cancellation of the repair task that has the ID MyRepairTaskId.
Parameters
-TaskId
Specifies the ID of the repair task to cancel.
Type: | String |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-TimeoutSec
Specifies the time-out period, in seconds, for the operation.
Type: | Int32 |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Version
Specifies the current version of the repair task. The request can succeed only if the value that this parameter specifies matches the current value of the repair task. Specify a value of zero (0) to skip version check.
Type: | Int64 |
Position: | 1 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
Inputs
System.String
System.Int64
Outputs
System.Object