Remove-​Service​Fabric​Repair​Task

Removes a completed repair task.

Syntax

Remove-ServiceFabricRepairTask
      [-TaskId] <String>
      [[-Version] <Int64>]
      [-TimeoutSec <Int32>]
      [<CommonParameters>]

Description

The Remove-ServiceFabricRepairTask cmdlet removes a completed Service Fabric repair task. In order to delete a repair task, it must be in 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: Remove a single repair task

PS C:\> Remove-ServiceFabricRepairTask -TaskId "MyRepairTaskID"

This command removes the repair task that has the ID MyRepairTaskID if it is completed.

Example 2: Remove all completed repair tasks

PS C:\> Get-ServiceFabricRepairTask -State Completed | Remove-ServiceFabricRepairTask

This command removes all completed repair tasks.

Required Parameters

-TaskId

Specifies the ID of the completed repair task that this cmdlet removes.

Type:String
Position:1
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False

Optional Parameters

-TimeoutSec

Specifies the time-out period, in seconds, for the operation.

Type:Int32
Position:Named
Default value:None
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:2
Default value:None
Accept pipeline input:True (ByPropertyName)
Accept wildcard characters:False

Inputs

String, Int64

This cmdlet accepts a task ID as a string or the version ID as an integer.

Outputs

None

This cmdlet does not return any output.