ResiliencehubV2 class
The next generation of AWS Resilience Hub is the single location in AWS where you assess and improve the resilience of your critical applications. It helps Site Reliability Engineers (SREs) and development teams proactively reason about resilience at scale — identifying failure modes, discovering hidden dependencies, and report on progress across the enterprise.
Constructors
- ResiliencehubV2({required String region, AwsClientCredentials? credentials, AwsClientCredentialsProvider? credentialsProvider, Client? client, String? endpointUrl, bool useFipsEndpoint = false, bool useDualStackEndpoint = false})
-
factory
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
close(
) → void - Closes the internal HTTP client if none was provided at creation. If a client was passed as a constructor argument, this becomes a noop.
-
createAssertion(
{required String serviceArn, required String text, String? clientToken}) → Future< CreateAssertionResponse> - Creates a resilience assertion for a service.
-
createInputSource(
{required ResourceConfiguration resourceConfiguration, required String serviceArn, String? clientToken}) → Future< CreateInputSourceResponse> - Creates an input source for a service.
-
createPolicy(
{required String name, AvailabilitySlo? availabilitySlo, String? clientToken, DataRecoveryTargets? dataRecovery, String? description, String? kmsKeyId, MultiAzTargets? multiAz, MultiRegionTargets? multiRegion, Map< String, String> ? tags}) → Future<CreatePolicyResponse> - Creates a resilience policy that defines availability and disaster recovery requirements.
-
createReport(
{required ReportType reportType, required String serviceArn, String? clientToken}) → Future< CreateReportResponse> - On-demand report creation. Idempotent — duplicate requests with same clientToken return existing result.
-
createService(
{required String name, required PermissionModel permissionModel, required List< String> regions, List<AssociatedSystem> ? associatedSystems, String? clientToken, DependencyDiscoveryInput? dependencyDiscovery, String? description, String? kmsKeyId, String? policyArn, ServiceReportConfiguration? reportConfiguration, Map<String, String> ? tags}) → Future<CreateServiceResponse> - Creates a service.
-
createServiceFunction(
{required ServiceFunctionCriticality criticality, required String name, required String serviceArn, String? clientToken, String? description}) → Future< CreateServiceFunctionResponse> - Creates a service function within a service.
-
createServiceFunctionResources(
{required List< String> resources, required String serviceArn, required String serviceFunctionId}) → Future<CreateServiceFunctionResourcesResponse> - Associates resources with a service function.
-
createSystem(
{required String name, String? clientToken, String? description, String? kmsKeyId, bool? sharingEnabled, Map< String, String> ? tags}) → Future<CreateSystemResponse> - Creates a system that represents a logical grouping of services.
-
createTest(
{required String serviceArn, required String testTemplateArn, LoggingConfiguration? loggingConfiguration, Map< String, List< ? parameters, String? roleName, List<String> >StopCondition> ? stopConditions}) → Future<CreateTestResponse> - Creates a test for a service by configuring a test template. Each service has one test per template.
-
createUserJourney(
{required String name, required String systemArn, String? clientToken, String? description, String? policyArn}) → Future< CreateUserJourneyResponse> - Creates a user journey within a system.
-
deleteAssertion(
{required String assertionId, required String serviceArn}) → Future< DeleteAssertionResponse> - Deletes a resilience assertion from a service.
-
deleteInputSource(
{required String inputSourceId, required String serviceArn}) → Future< DeleteInputSourceResponse> - Deletes an input source.
-
deletePolicy(
{required String policyArn}) → Future< DeletePolicyResponse> - Deletes a resilience policy.
-
deleteService(
{required String serviceArn}) → Future< DeleteServiceResponse> - Deletes a service.
-
deleteServiceFunction(
{required String serviceArn, required String serviceFunctionId}) → Future< DeleteServiceFunctionResponse> - Deletes a service function.
-
deleteServiceFunctionResources(
{required List< String> resources, required String serviceArn, required String serviceFunctionId}) → Future<DeleteServiceFunctionResourcesResponse> - Removes resources from a service function.
-
deleteSystem(
{required String systemArn}) → Future< DeleteSystemResponse> - Deletes a system.
-
deleteTest(
{required String serviceArn, required String testId}) → Future< DeleteTestResponse> - Deletes a test.
-
deleteTestSources(
{required String serviceArn, required String testId, required List< TestSourceInput> testSources}) → Future<void> - Removes monitoring sources from a test. The operation is transactional and idempotent — removing a source that is not attached is a no-op.
-
deleteUserJourney(
{required String systemArn, required String userJourneyId}) → Future< DeleteUserJourneyResponse> - Deletes a user journey.
-
getFailureModeFinding(
{required String findingId, required String serviceArn}) → Future< GetFailureModeFindingResponse> - Retrieves a finding by findingId.
-
getPolicy(
{required String policyArn}) → Future< GetPolicyResponse> - Retrieves a resilience policy by ARN.
-
getService(
{required String serviceArn}) → Future< GetServiceResponse> - Retrieves a service by ARN.
-
getSystem(
{required String systemArn}) → Future< GetSystemResponse> - Retrieves a system by ARN.
-
getTest(
{required String serviceArn, required String testId}) → Future< GetTestResponse> - Retrieves a test by ID.
-
getTestRun(
{required String serviceArn, required String testRunId}) → Future< GetTestRunResponse> - Retrieves a test run by ID, including its status, results, and the configuration snapshotted when the run started.
-
getTestTemplate(
{required String testTemplateArn}) → Future< GetTestTemplateResponse> - Retrieves a resilience test template by ARN, including the parameters it accepts and the fault actions it runs.
-
getUserJourney(
{required String systemArn, required String userJourneyId}) → Future< GetUserJourneyResponse> - Retrieves a user journey.
-
importApp(
{required String v1AppArn, List< AssociatedSystem> ? associatedSystems, String? clientToken, String? kmsKeyId, String? policyArn, bool? skipManuallyAddedResources, Map<String, String> ? tags}) → Future<ImportAppResponse> - Imports a V1 app into the V2 resource model, creating a service with the same name.
-
importPolicy(
{required String v1PolicyArn, AvailabilitySlo? availabilitySlo, String? clientToken, String? kmsKeyId, MultiAzDisasterRecoveryApproach? multiAzDisasterRecoveryApproach, MultiRegionDisasterRecoveryApproach? multiRegionDisasterRecoveryApproach, Map< String, String> ? tags}) → Future<ImportPolicyResponse> - Imports a V1 policy into V2, mapping RTO/RPO values from V1 scenarios.
-
listAssertions(
{required String serviceArn, int? maxResults, String? nextToken, AssertionSource? source}) → Future< ListAssertionsResponse> - Lists resilience assertions for a service.
-
listDependencies(
{int? maxResults, String? nextToken, DateTime? queryRangeEndTime, QueryGranularity? queryRangeGranularity, DateTime? queryRangeStartTime, String? serviceArn}) → Future< ListDependenciesResponse> - Lists dependencies discovered for services.
-
listFailureModeAssessments(
{required String serviceArn, List< AssessmentStatus> ? assessmentStatuses, DateTime? endedBefore, int? maxResults, String? nextToken, AssessmentSortField? sortBy, SortOrder? sortOrder, DateTime? startedAfter}) → Future<ListFailureModeAssessmentsResponse> - Lists failure mode assessments.
-
listFailureModeFindings(
{required String serviceArn, FailureCategory? failureCategory, int? maxResults, String? nextToken, FindingSeverity? severity, FindingStatus? status}) → Future< ListFailureModeFindingsResponse> - List findings.
-
listInputSources(
{required String serviceArn, int? maxResults, String? nextToken, InputSourceType? type}) → Future< ListInputSourcesResponse> - Lists input sources for a service.
-
listPolicies(
{int? maxResults, String? nextToken}) → Future< ListPoliciesResponse> - Lists resilience policies.
-
listReports(
{int? maxResults, String? nextToken, ReportType? reportType, String? serviceArn, String? testRunId}) → Future< ListReportsResponse> - List reports for a service, or all reports owned by the account if serviceArn is not provided.
-
listResolvedTestRunTargetResources(
{required String serviceArn, required String testRunId, int? maxResults, String? nextToken}) → Future< ListResolvedTestRunTargetResourcesResponse> - Lists the AWS resources that AWS Fault Injection Service (AWS FIS) resolved as targets for a test run.
-
listResources(
{required String serviceArn, String? awsRegion, bool? billable, int? maxResults, String? nextToken, List< String> ? resourceTypes, String? serviceFunctionId}) → Future<ListResourcesResponse> - List resources.
-
listServiceEvents(
{required String serviceArn, DateTime? endTime, List< ServiceEventType> ? eventTypes, int? maxResults, String? nextToken, DateTime? startTime}) → Future<ListServiceEventsResponse> - Lists events for a service.
-
listServiceFunctions(
{required String serviceArn, int? maxResults, String? nextToken}) → Future< ListServiceFunctionsResponse> - Lists service functions for a service.
-
listServices(
{String? accountId, AssessmentStatus? assessmentStatus, int? maxResults, String? nextToken, String? ouId, String? policyArn, String? systemArn, String? userJourneyId}) → Future< ListServicesResponse> - Lists services.
-
listServiceTopologyEdges(
{required String serviceArn, int? maxResults, String? nextToken}) → Future< ListServiceTopologyEdgesResponse> - Lists topology edges for a service.
-
listSystemEvents(
{required String systemArn, DateTime? endTime, List< SystemEventType> ? eventTypes, int? maxResults, String? nextToken, DateTime? startTime}) → Future<ListSystemEventsResponse> - Lists events for a system.
-
listSystems(
{int? maxResults, String? nextToken, String? ouId}) → Future< ListSystemsResponse> - Lists systems.
-
listTagsForResource(
{required String resourceArn}) → Future< ListTagsForResourceResponse> - Lists the tags for a resource.
-
listTestRunEvents(
{required String serviceArn, required String testRunId, DateTime? endedAt, int? maxResults, String? nextToken, DateTime? startedAt}) → Future< ListTestRunEventsResponse> - Lists the events in a test run's timeline.
-
listTestRuns(
{required String serviceArn, int? maxResults, String? nextToken, String? testId}) → Future< ListTestRunsResponse> - Lists the runs of a test, or all test runs for a service.
-
listTestRunSources(
{required String serviceArn, required String testRunId, int? maxResults, String? nextToken, TestRunSourceType? type}) → Future< ListTestRunSourcesResponse> - Lists the monitoring source snapshots captured for a test run, optionally filtered by type.
-
listTests(
{required String serviceArn, int? maxResults, String? nextToken}) → Future< ListTestsResponse> - Lists the tests configured for a service.
-
listTestSources(
{required String serviceArn, required String testId, int? maxResults, String? nextToken, TestSourceType? type}) → Future< ListTestSourcesResponse> - Lists the monitoring sources attached to a test, optionally filtered by type.
-
listTestTemplates(
) → Future< ListTestTemplatesResponse> - Lists the available resilience test templates. A test template is a pre-configured, AWS recommended test that defines which resilience capability to validate.
-
listUserJourneys(
{required String systemArn, int? maxResults, String? nextToken}) → Future< ListUserJourneysResponse> - Lists user journeys for a system.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
putTestSources(
{required String serviceArn, required String testId, required List< TestSourceInput> testSources}) → Future<void> - Adds or updates the monitoring sources on a test. The operation is transactional — either every source is written or the call fails and nothing is written.
-
startFailureModeAssessment(
{required String serviceArn, String? clientToken}) → Future< StartFailureModeAssessmentResponse> - Starts a failure mode assessment.
-
startTestRun(
{required String serviceArn, required String testId}) → Future< StartTestRunResponse> - Starts a run of a test. Each run scopes to the current resources in the service and produces a pass or fail outcome.
-
stopTestRun(
{required String serviceArn, required String testRunId}) → Future< StopTestRunResponse> - Stops an in-progress test run.
-
tagResource(
{required String resourceArn, required Map< String, String> tags}) → Future<void> - Adds tags to a resource.
-
toString(
) → String -
A string representation of this object.
inherited
-
untagResource(
{required String resourceArn, required List< String> tagKeys}) → Future<void> - Removes tags from a resource.
-
updateAssertion(
{required String assertionId, required String serviceArn, String? text}) → Future< UpdateAssertionResponse> - Updates a resilience assertion.
-
updateDependency(
{required String dependencyId, required String serviceArn, String? comment, DependencyCriticality? criticality}) → Future< UpdateDependencyResponse> - Updates a dependency classification.
-
updateFailureModeFinding(
{required String findingId, required String serviceArn, required FindingStatus status, String? comment}) → Future< UpdateFailureModeFindingResponse> - Updates an existing finding.
-
updatePolicy(
{required String policyArn, AvailabilitySlo? availabilitySlo, DataRecoveryTargets? dataRecovery, String? description, MultiAzTargets? multiAz, MultiRegionTargets? multiRegion}) → Future< UpdatePolicyResponse> - Updates an existing resilience policy.
-
updateService(
{required String serviceArn, List< AssociatedSystem> ? associatedSystems, DependencyDiscoveryInput? dependencyDiscovery, String? description, PermissionModel? permissionModel, String? policyArn, List<String> ? regions, ServiceReportConfiguration? reportConfiguration}) → Future<UpdateServiceResponse> - Updates an existing service.
-
updateServiceFunction(
{required String serviceArn, required String serviceFunctionId, ServiceFunctionCriticality? criticality, String? description, String? name}) → Future< UpdateServiceFunctionResponse> - Updates a service function.
-
updateSystem(
{required String systemArn, String? description, bool? sharingEnabled}) → Future< UpdateSystemResponse> - Updates an existing system.
-
updateTest(
{required String serviceArn, required String testId, LoggingConfiguration? loggingConfiguration, Map< String, List< ? parameters, String? roleName, List<String> >StopCondition> ? stopConditions}) → Future<UpdateTestResponse> - Updates the configuration of an existing test.
-
updateUserJourney(
{required String systemArn, required String userJourneyId, String? description, String? name, String? policyArn}) → Future< UpdateUserJourneyResponse> - Updates an existing user journey.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited