Share via


FabricClient.TestManagementClient.StartPartitionRestartAsync Method

Definition

Overloads

StartPartitionRestartAsync(Guid, PartitionSelector, RestartPartitionMode, TimeSpan)

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.

StartPartitionRestartAsync(Guid, PartitionSelector, RestartPartitionMode)

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.

StartPartitionRestartAsync(Guid, PartitionSelector, RestartPartitionMode, CancellationToken)

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.

StartPartitionRestartAsync(Guid, PartitionSelector, RestartPartitionMode, TimeSpan, CancellationToken)

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.

StartPartitionRestartAsync(Guid, PartitionSelector, RestartPartitionMode, TimeSpan)

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.

public System.Threading.Tasks.Task StartPartitionRestartAsync (Guid operationId, System.Fabric.PartitionSelector partitionSelector, System.Fabric.RestartPartitionMode restartPartitionMode, TimeSpan operationTimeout);
member this.StartPartitionRestartAsync : Guid * System.Fabric.PartitionSelector * System.Fabric.RestartPartitionMode * TimeSpan -> System.Threading.Tasks.Task
Public Function StartPartitionRestartAsync (operationId As Guid, partitionSelector As PartitionSelector, restartPartitionMode As RestartPartitionMode, operationTimeout As TimeSpan) As Task

Parameters

operationId
Guid

A GUID that identifies a call of this API; this is passed into the corresponding GetProgress API

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

A task.

Exceptions

Action took more than its allocated time.

Any of the required arguments are null.

The input was invalid.

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 may be called on both stateful and stateless services. If the call is on a stateless service, RestartPartitionMode must be RestartPartitionMode.AllReplicasOrInstances. Other modes will result in ArgumentException inside the returned Result object when GetPartitionRestartProgressAsync() is called. See GetPartitionRestartProgressAsync().

The FaultAnalysisService must be enabled to use this API.

Applies to

StartPartitionRestartAsync(Guid, PartitionSelector, RestartPartitionMode)

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.

public System.Threading.Tasks.Task StartPartitionRestartAsync (Guid operationId, System.Fabric.PartitionSelector partitionSelector, System.Fabric.RestartPartitionMode restartPartitionMode);
member this.StartPartitionRestartAsync : Guid * System.Fabric.PartitionSelector * System.Fabric.RestartPartitionMode -> System.Threading.Tasks.Task
Public Function StartPartitionRestartAsync (operationId As Guid, partitionSelector As PartitionSelector, restartPartitionMode As RestartPartitionMode) As Task

Parameters

operationId
Guid

A GUID that identifies a call of this API; this is passed into the corresponding GetProgress API

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

A task.

Exceptions

Action took more than its allocated time.

Any of the required arguments are null.

The input was invalid.

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 may be called on both stateful and stateless services. If the call is on a stateless service, RestartPartitionMode must be RestartPartitionMode.AllReplicasOrInstances. Other modes will result in ArgumentException inside the returned Result object when GetPartitionRestartProgressAsync() is called. See GetPartitionRestartProgressAsync().

The FaultAnalysisService must be enabled to use this API.

Applies to

StartPartitionRestartAsync(Guid, PartitionSelector, RestartPartitionMode, CancellationToken)

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.

public System.Threading.Tasks.Task StartPartitionRestartAsync (Guid operationId, System.Fabric.PartitionSelector partitionSelector, System.Fabric.RestartPartitionMode restartPartitionMode, System.Threading.CancellationToken cancellationToken);
member this.StartPartitionRestartAsync : Guid * System.Fabric.PartitionSelector * System.Fabric.RestartPartitionMode * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Function StartPartitionRestartAsync (operationId As Guid, partitionSelector As PartitionSelector, restartPartitionMode As RestartPartitionMode, cancellationToken As CancellationToken) As Task

Parameters

operationId
Guid

A GUID that identifies a call of this API; this is passed into the corresponding GetProgress API

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

A task.

Exceptions

Action took more than its allocated time.

Any of the required arguments are null.

The input was invalid.

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 may be called on both stateful and stateless services. If the call is on a stateless service, RestartPartitionMode must be RestartPartitionMode.AllReplicasOrInstances. Other modes will result in ArgumentException inside the returned Result object when GetPartitionRestartProgressAsync() is called. See GetPartitionRestartProgressAsync().

Applies to

StartPartitionRestartAsync(Guid, PartitionSelector, RestartPartitionMode, TimeSpan, CancellationToken)

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.

public System.Threading.Tasks.Task StartPartitionRestartAsync (Guid operationId, System.Fabric.PartitionSelector partitionSelector, System.Fabric.RestartPartitionMode restartPartitionMode, TimeSpan operationTimeout, System.Threading.CancellationToken cancellationToken);
member this.StartPartitionRestartAsync : Guid * System.Fabric.PartitionSelector * System.Fabric.RestartPartitionMode * TimeSpan * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Function StartPartitionRestartAsync (operationId As Guid, partitionSelector As PartitionSelector, restartPartitionMode As RestartPartitionMode, operationTimeout As TimeSpan, cancellationToken As CancellationToken) As Task

Parameters

operationId
Guid

A GUID that identifies a call of this API; this is passed into the corresponding GetProgress API

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

A task.

Exceptions

Action took more than its allocated time.

Any of the required arguments are null.

The input was invalid.

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 may be called on both stateful and stateless services. If the call is on a stateless service, RestartPartitionMode must be RestartPartitionMode.AllReplicasOrInstances. Other modes will result in ArgumentException inside the returned Result object when GetPartitionRestartProgressAsync() is called. See GetPartitionRestartProgressAsync().

The FaultAnalysisService must be enabled to use this API.

Applies to