class AwsRDSClusterContainer extends AwsContainer {

    @ChaosExperiment(experimentType = ExperimentType.STATE)
    public void startSnapshot (Experiment experiment) {
        experiment.setCheckContainerHealth(() -> awsRDSPlatform.isClusterSnapshotRunning(dbClusterIdentifier) ? ContainerHealth.RUNNING_EXPERIMENT : ContainerHealth.NORMAL);
        final DBClusterSnapshot dbClusterSnapshot = awsRDSPlatform.snapshotDBCluster(dbClusterIdentifier);
        experiment.setSelfHealingMethod(() -> {
            try {
                awsRDSPlatform.deleteClusterSnapshot(dbClusterSnapshot);
            } catch (DBClusterNotFoundException e) {
                log.warn("Tried to clean up cluster snapshot, but it was already deleted", v(DataDogConstants.RDS_CLUSTER_SNAPSHOT, dbClusterSnapshot), e);
            }
        });
        experiment.setFinalizeMethod(experiment.getSelfHealingMethod());
        // On finalize clean up the snapshot.
    }

}