C# Class ChaosTest.ChaosService.ChaosService

This stateful service keeps inducing failovers and faults - chosen probabilistically - to the cluster, using ChaosTestScenario from Microsoft.ServiceFabric.Testability under the hood, hiding the fact that ChaosTestScenario runs in unit of iteration, giving the impression that the fault inducing is perennial.
Inheritance: StatefulService
Afficher le fichier Open project: Azure-Samples/service-fabric-dotnet-testing-chaos-service Class Usage Examples

Méthodes publiques

Méthode Description
ChaosService ( StatefulServiceContext context ) : System
GetEventsAsync ( ) : Task
StartAsync ( ) : Task

Starts the test.

StopAsync ( ) : Task

Méthodes protégées

Méthode Description
CreateServiceReplicaListeners ( ) : IEnumerable
RunAsync ( CancellationToken runAsyncCancellationToken ) : Task

Private Methods

Méthode Description
StoreEventAsync ( string eventString ) : Task

This method saves the description (eventString) and timestamp of the recentmost induced fault as a ChaosEntry in a Reliable Dictionary

TestScenarioProgressChanged ( object sender, ProgressChangedEventArgs e ) : void

This is the event-handler for the events coming into from ChaosTestScenario

Method Details

ChaosService() public méthode

public ChaosService ( StatefulServiceContext context ) : System
context StatefulServiceContext
Résultat System

CreateServiceReplicaListeners() protected méthode

protected CreateServiceReplicaListeners ( ) : IEnumerable
Résultat IEnumerable

GetEventsAsync() public méthode

public GetEventsAsync ( ) : Task
Résultat Task

RunAsync() protected méthode

protected RunAsync ( CancellationToken runAsyncCancellationToken ) : Task
runAsyncCancellationToken System.Threading.CancellationToken
Résultat Task

StartAsync() public méthode

Starts the test.
public StartAsync ( ) : Task
Résultat Task

StopAsync() public méthode

public StopAsync ( ) : Task
Résultat Task