Udostępnij za pośrednictwem


FabricClient.TestManagementClient.RestartPartitionAsync Method

Definition

Overloads

RestartPartitionAsync(PartitionSelector, RestartPartitionMode)
Obsolete.

This API will restart some or all the replicas of a partition at the same time (ensures all the replicas are down concurrently) depending on the RestartPartitionMode.

RestartPartitionAsync(PartitionSelector, RestartPartitionMode, CancellationToken)
Obsolete.

This API will restart some or all the replicas of a partition at the same time (ensures all the replicas are down concurrently) depending on the RestartPartitionMode.

RestartPartitionAsync(PartitionSelector, RestartPartitionMode, TimeSpan)
Obsolete.

This API will restart some or all the replicas of a partition at the same time (ensures all the replicas are down concurrently) depending on the RestartPartitionMode.

RestartPartitionAsync(PartitionSelector, RestartPartitionMode, TimeSpan, CancellationToken)
Obsolete.

This API will restart some or all the replicas of a partition at the same time (ensures all the replicas are down concurrently) depending on the RestartPartitionMode.

RestartPartitionAsync(PartitionSelector, RestartPartitionMode)

Caution

This api is deprecated, use StartPartitionRestartAsync instead. StartPartitionRestartAsync requires the FaultAnalysisService

This API will restart some or all the replicas of a partition at the same time (ensures all the replicas are down concurrently) depending on the RestartPartitionMode.

[System.Obsolete("This api is deprecated, use StartPartitionRestartAsync instead.  StartPartitionRestartAsync requires the FaultAnalysisService")]
public System.Threading.Tasks.Task<System.Fabric.Result.RestartPartitionResult> RestartPartitionAsync (System.Fabric.PartitionSelector partitionSelector, System.Fabric.RestartPartitionMode restartPartitionMode);
[<System.Obsolete("This api is deprecated, use StartPartitionRestartAsync instead.  StartPartitionRestartAsync requires the FaultAnalysisService")>]
member this.RestartPartitionAsync : System.Fabric.PartitionSelector * System.Fabric.RestartPartitionMode -> System.Threading.Tasks.Task<System.Fabric.Result.RestartPartitionResult>
Public Function RestartPartitionAsync (partitionSelector As PartitionSelector, restartPartitionMode As RestartPartitionMode) As Task(Of RestartPartitionResult)

Parameters

partitionSelector
PartitionSelector

PartitionSelector that specifies the partition which needs to be restarted.

restartPartitionMode
RestartPartitionMode

The RestartPartitionMode which can be AllReplicasOrInstances or OnlyActiveSecondaries based on which the replicas to be restarted are selected.

Returns

RestartPartitionResult which gives information about the actual selected partition.

Attributes

Exceptions

Action took more than its allocated time.

Any of the required arguments are null.

If the API is called for a partition belonging to a stateless service with RestartPartitionMode set to OnlyActiveSecondaries.

These are the fabric failures FabricErrorCode.PartitionNotFound - if the specified partition selected does not exist.

Remarks

This API is useful to test the recovery time of a partition after a full or partial restart and also to test failover.

This API should only be called with a stateful service as the target.

Important note: this API should not be aborted while running. Aborting this API while it is running may leave state behind. If this API is aborted while running, CleanTestStateAsync() should be invoked to remove state that may have been left behind.

Applies to

RestartPartitionAsync(PartitionSelector, RestartPartitionMode, CancellationToken)

Caution

This api is deprecated, use StartPartitionRestartAsync instead. StartPartitionRestartAsync requires the FaultAnalysisService

This API will restart some or all the replicas of a partition at the same time (ensures all the replicas are down concurrently) depending on the RestartPartitionMode.

[System.Obsolete("This api is deprecated, use StartPartitionRestartAsync instead.  StartPartitionRestartAsync requires the FaultAnalysisService")]
public System.Threading.Tasks.Task<System.Fabric.Result.RestartPartitionResult> RestartPartitionAsync (System.Fabric.PartitionSelector partitionSelector, System.Fabric.RestartPartitionMode restartPartitionMode, System.Threading.CancellationToken cancellationToken);
[<System.Obsolete("This api is deprecated, use StartPartitionRestartAsync instead.  StartPartitionRestartAsync requires the FaultAnalysisService")>]
member this.RestartPartitionAsync : System.Fabric.PartitionSelector * System.Fabric.RestartPartitionMode * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.Fabric.Result.RestartPartitionResult>
Public Function RestartPartitionAsync (partitionSelector As PartitionSelector, restartPartitionMode As RestartPartitionMode, cancellationToken As CancellationToken) As Task(Of RestartPartitionResult)

Parameters

partitionSelector
PartitionSelector

PartitionSelector that specifies the partition which needs to be restarted

restartPartitionMode
RestartPartitionMode

The RestartPartitionMode which can be AllReplicasOrInstances or OnlyActiveSecondaries based on which the replicas to be restarted are selected.

cancellationToken
CancellationToken

This token can be signalled to abort this operation before it finishes

Returns

RestartPartitionResult which gives information about the actual selected partition

Attributes

Exceptions

Action took more than its allocated time.

Any of the required arguments are null.

If the API is called for a partition belonging to a stateless service with RestartPartitionMode set to OnlyActiveSecondaries.

These are the fabric failures FabricErrorCode.PartitionNotFound - if the specified partition selected does not exist

Remarks

This API is useful to test the recovery time of a partition after a full or partial restart and also to test failover.

This API should only be called with a stateful service as the target.

Important note: this API should not be aborted while running. Aborting this API while it is running may leave state behind. If this API is aborted while running, CleanTestStateAsync() should be invoked to remove state that may have been left behind.

Applies to

RestartPartitionAsync(PartitionSelector, RestartPartitionMode, TimeSpan)

Caution

This api is deprecated, use StartPartitionRestartAsync instead. StartPartitionRestartAsync requires the FaultAnalysisService

This API will restart some or all the replicas of a partition at the same time (ensures all the replicas are down concurrently) depending on the RestartPartitionMode.

[System.Obsolete("This api is deprecated, use StartPartitionRestartAsync instead.  StartPartitionRestartAsync requires the FaultAnalysisService")]
public System.Threading.Tasks.Task<System.Fabric.Result.RestartPartitionResult> RestartPartitionAsync (System.Fabric.PartitionSelector partitionSelector, System.Fabric.RestartPartitionMode restartPartitionMode, TimeSpan operationTimeout);
[<System.Obsolete("This api is deprecated, use StartPartitionRestartAsync instead.  StartPartitionRestartAsync requires the FaultAnalysisService")>]
member this.RestartPartitionAsync : System.Fabric.PartitionSelector * System.Fabric.RestartPartitionMode * TimeSpan -> System.Threading.Tasks.Task<System.Fabric.Result.RestartPartitionResult>
Public Function RestartPartitionAsync (partitionSelector As PartitionSelector, restartPartitionMode As RestartPartitionMode, operationTimeout As TimeSpan) As Task(Of RestartPartitionResult)

Parameters

partitionSelector
PartitionSelector

PartitionSelector that specifies the partition which needs to be restarted.

restartPartitionMode
RestartPartitionMode

The RestartPartitionMode which can be AllReplicasOrInstances or OnlyActiveSecondaries based on which the replicas to be restarted are selected.

operationTimeout
TimeSpan

The overall timeout for the operation.

Returns

RestartPartitionResult which gives information about the actual selected partition.

Attributes

Exceptions

Action took more than its allocated time.

Any of the required arguments are null.

If the API is called for a partition belonging to a stateless service with RestartPartitionMode set to OnlyActiveSecondaries.

These are the fabric failures FabricErrorCode.PartitionNotFound - if the specified partition selected does not exist

Remarks

This API is useful to test the recovery time of a partition after a full or partial restart and also to test failover.

This API should only be called with a stateful service as the target.

Important note: this API should not be aborted while running. Aborting this API while it is running may leave state behind. If this API is aborted while running, CleanTestStateAsync() should be invoked to remove state that may have been left behind.

Applies to

RestartPartitionAsync(PartitionSelector, RestartPartitionMode, TimeSpan, CancellationToken)

Caution

This api is deprecated, use StartPartitionRestartAsync instead. StartPartitionRestartAsync requires the FaultAnalysisService

This API will restart some or all the replicas of a partition at the same time (ensures all the replicas are down concurrently) depending on the RestartPartitionMode.

[System.Obsolete("This api is deprecated, use StartPartitionRestartAsync instead.  StartPartitionRestartAsync requires the FaultAnalysisService")]
public System.Threading.Tasks.Task<System.Fabric.Result.RestartPartitionResult> RestartPartitionAsync (System.Fabric.PartitionSelector partitionSelector, System.Fabric.RestartPartitionMode restartPartitionMode, TimeSpan operationTimeout, System.Threading.CancellationToken cancellationToken);
[<System.Obsolete("This api is deprecated, use StartPartitionRestartAsync instead.  StartPartitionRestartAsync requires the FaultAnalysisService")>]
member this.RestartPartitionAsync : System.Fabric.PartitionSelector * System.Fabric.RestartPartitionMode * TimeSpan * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.Fabric.Result.RestartPartitionResult>
Public Function RestartPartitionAsync (partitionSelector As PartitionSelector, restartPartitionMode As RestartPartitionMode, operationTimeout As TimeSpan, cancellationToken As CancellationToken) As Task(Of RestartPartitionResult)

Parameters

partitionSelector
PartitionSelector

PartitionSelector that specifies the partition which needs to be restarted.

restartPartitionMode
RestartPartitionMode

The RestartPartitionMode which can be AllReplicasOrInstances or OnlyActiveSecondaries based on which the replicas to be restarted are selected.

operationTimeout
TimeSpan

The overall timeout for the operation.

cancellationToken
CancellationToken

This token can be signalled to abort this operation before it finishes

Returns

RestartPartitionResult which gives information about the actual selected partition.

Attributes

Exceptions

Action took more than its allocated time.

Any of the required arguments are null.

If the API is called for a partition belonging to a stateless service with RestartPartitionMode set to OnlyActiveSecondaries.

These are the fabric failures FabricErrorCode.PartitionNotFound - if the specified partition selected does not exist

Remarks

This API is useful to test the recovery time of a partition after a full or partial restart and also to test failover.

This API should only be called with a stateful service as the target.

Important note: this API should not be aborted while running. Aborting this API while it is running may leave state behind. If this API is aborted while running, CleanTestStateAsync() should be invoked to remove state that may have been left behind.

Applies to