Class: Aws::Resiliencehubv2::Client

Inherits:
Seahorse::Client::Base show all
Includes:
ClientStubs
Defined in:
gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb

Overview

An API client for Resiliencehubv2. To construct a client, you need to configure a :region and :credentials.

client = Aws::Resiliencehubv2::Client.new(
  region: region_name,
  credentials: credentials,
  # ...
)

For details on configuring region and credentials see the developer guide.

See #initialize for a full list of supported configuration options.

Instance Attribute Summary

Attributes inherited from Seahorse::Client::Base

#config, #handlers

API Operations collapse

Instance Method Summary collapse

Methods included from ClientStubs

#api_requests, #stub_data, #stub_responses

Methods inherited from Seahorse::Client::Base

add_plugin, api, clear_plugins, define, new, #operation_names, plugins, remove_plugin, set_api, set_plugins

Methods included from Seahorse::Client::HandlerBuilder

#handle, #handle_request, #handle_response

Constructor Details

#initialize(options) ⇒ Client

Returns a new instance of Client.

Parameters:

  • options (Hash)

Options Hash (options):

  • :plugins (Array<Seahorse::Client::Plugin>) — default: []]

    A list of plugins to apply to the client. Each plugin is either a class name or an instance of a plugin class.

  • :credentials (required, Aws::CredentialProvider)

    Your AWS credentials used for authentication. This can be any class that includes and implements Aws::CredentialProvider, or instance of any one of the following classes:

    • Aws::Credentials - Used for configuring static, non-refreshing credentials.

    • Aws::SharedCredentials - Used for loading static credentials from a shared file, such as ~/.aws/config.

    • Aws::AssumeRoleCredentials - Used when you need to assume a role.

    • Aws::AssumeRoleWebIdentityCredentials - Used when you need to assume a role after providing credentials via the web.

    • Aws::SSOCredentials - Used for loading credentials from AWS SSO using an access token generated from aws login.

    • Aws::ProcessCredentials - Used for loading credentials from a process that outputs to stdout.

    • Aws::InstanceProfileCredentials - Used for loading credentials from an EC2 IMDS on an EC2 instance.

    • Aws::ECSCredentials - Used for loading credentials from instances running in ECS.

    • Aws::CognitoIdentityCredentials - Used for loading credentials from the Cognito Identity service.

    When :credentials are not configured directly, the following locations will be searched for credentials:

    • Aws.config[:credentials]

    • The :access_key_id, :secret_access_key, :session_token, and :account_id options.

    • ENV['AWS_ACCESS_KEY_ID'], ENV['AWS_SECRET_ACCESS_KEY'], ENV['AWS_SESSION_TOKEN'], and ENV['AWS_ACCOUNT_ID'].

    • ~/.aws/credentials

    • ~/.aws/config

    • EC2/ECS IMDS instance profile - When used by default, the timeouts are very aggressive. Construct and pass an instance of Aws::InstanceProfileCredentials or Aws::ECSCredentials to enable retries and extended timeouts. Instance profile credential fetching can be disabled by setting ENV['AWS_EC2_METADATA_DISABLED'] to true.

  • :region (required, String)

    The AWS region to connect to. The configured :region is used to determine the service :endpoint. When not passed, a default :region is searched for in the following locations:

    • Aws.config[:region]
    • ENV['AWS_REGION']
    • ENV['AMAZON_REGION']
    • ENV['AWS_DEFAULT_REGION']
    • ~/.aws/credentials
    • ~/.aws/config
  • :access_key_id (String)
  • :account_id (String)
  • :active_endpoint_cache (Boolean) — default: false

    When set to true, a thread polling for endpoints will be running in the background every 60 secs (default). Defaults to false.

  • :adaptive_retry_wait_to_fill (Boolean) — default: true

    Used only in adaptive retry mode. When true, the request will sleep until there is sufficent client side capacity to retry the request. When false, the request will raise a RetryCapacityNotAvailableError and will not retry instead of sleeping.

  • :auth_scheme_preference (Array<String>)

    A list of preferred authentication schemes to use when making a request. Supported values are: sigv4, sigv4a, httpBearerAuth, and noAuth. When set using ENV['AWS_AUTH_SCHEME_PREFERENCE'] or in shared config as auth_scheme_preference, the value should be a comma-separated list.

  • :client_side_monitoring (Boolean) — default: false

    When true, client-side metrics will be collected for all API requests from this client.

  • :client_side_monitoring_client_id (String) — default: ""

    Allows you to provide an identifier for this client which will be attached to all generated client side metrics. Defaults to an empty string.

  • :client_side_monitoring_host (String) — default: "127.0.0.1"

    Allows you to specify the DNS hostname or IPv4 or IPv6 address that the client side monitoring agent is running on, where client metrics will be published via UDP.

  • :client_side_monitoring_port (Integer) — default: 31000

    Required for publishing client metrics. The port that the client side monitoring agent is running on, where client metrics will be published via UDP.

  • :client_side_monitoring_publisher (Aws::ClientSideMonitoring::Publisher) — default: Aws::ClientSideMonitoring::Publisher

    Allows you to provide a custom client-side monitoring publisher class. By default, will use the Client Side Monitoring Agent Publisher.

  • :convert_params (Boolean) — default: true

    When true, an attempt is made to coerce request parameters into the required types.

  • :correct_clock_skew (Boolean) — default: true

    Used only in standard and adaptive retry modes. Specifies whether to apply a clock skew correction and retry requests with skewed client clocks.

  • :defaults_mode (String) — default: "legacy"

    See DefaultsModeConfiguration for a list of the accepted modes and the configuration defaults that are included.

  • :disable_host_prefix_injection (Boolean) — default: false

    When true, the SDK will not prepend the modeled host prefix to the endpoint.

  • :disable_request_compression (Boolean) — default: false

    When set to 'true' the request body will not be compressed for supported operations.

  • :endpoint (String, URI::HTTPS, URI::HTTP)

    Normally you should not configure the :endpoint option directly. This is normally constructed from the :region option. Configuring :endpoint is normally reserved for connecting to test or custom endpoints. The endpoint should be a URI formatted like:

    'http://example.com'
    'https://example.com'
    'http://example.com:123'
    
  • :endpoint_cache_max_entries (Integer) — default: 1000

    Used for the maximum size limit of the LRU cache storing endpoints data for endpoint discovery enabled operations. Defaults to 1000.

  • :endpoint_cache_max_threads (Integer) — default: 10

    Used for the maximum threads in use for polling endpoints to be cached, defaults to 10.

  • :endpoint_cache_poll_interval (Integer) — default: 60

    When :endpoint_discovery and :active_endpoint_cache is enabled, Use this option to config the time interval in seconds for making requests fetching endpoints information. Defaults to 60 sec.

  • :endpoint_discovery (Boolean) — default: false

    When set to true, endpoint discovery will be enabled for operations when available.

  • :ignore_configured_endpoint_urls (Boolean)

    Setting to true disables use of endpoint URLs provided via environment variables and the shared configuration file.

  • :log_formatter (Aws::Log::Formatter) — default: Aws::Log::Formatter.default

    The log formatter.

  • :log_level (Symbol) — default: :info

    The log level to send messages to the :logger at.

  • :logger (Logger)

    The Logger instance to send log messages to. If this option is not set, logging will be disabled.

  • :max_attempts (Integer) — default: 3

    An integer representing the maximum number attempts that will be made for a single request, including the initial attempt. For example, setting this value to 5 will result in a request being retried up to 4 times. Used in standard and adaptive retry modes.

  • :profile (String) — default: "default"

    Used when loading credentials from the shared credentials file at HOME/.aws/credentials. When not specified, 'default' is used.

  • :request_checksum_calculation (String) — default: "when_supported"

    Determines when a checksum will be calculated for request payloads. Values are:

    • when_supported - (default) When set, a checksum will be calculated for all request payloads of operations modeled with the httpChecksum trait where requestChecksumRequired is true and/or a requestAlgorithmMember is modeled.
    • when_required - When set, a checksum will only be calculated for request payloads of operations modeled with the httpChecksum trait where requestChecksumRequired is true or where a requestAlgorithmMember is modeled and supplied.
  • :request_min_compression_size_bytes (Integer) — default: 10240

    The minimum size in bytes that triggers compression for request bodies. The value must be non-negative integer value between 0 and 10485780 bytes inclusive.

  • :response_checksum_validation (String) — default: "when_supported"

    Determines when checksum validation will be performed on response payloads. Values are:

    • when_supported - (default) When set, checksum validation is performed on all response payloads of operations modeled with the httpChecksum trait where responseAlgorithms is modeled, except when no modeled checksum algorithms are supported.
    • when_required - When set, checksum validation is not performed on response payloads of operations unless the checksum algorithm is supported and the requestValidationModeMember member is set to ENABLED.
  • :retry_backoff (Proc)

    A proc or lambda used for backoff. Defaults to 2**retries * retry_base_delay. This option is only used in the legacy retry mode.

  • :retry_base_delay (Float) — default: 0.3

    The base delay in seconds used by the default backoff function. This option is only used in the legacy retry mode.

  • :retry_jitter (Symbol) — default: :none

    A delay randomiser function used by the default backoff function. Some predefined functions can be referenced by name - :none, :equal, :full, otherwise a Proc that takes and returns a number. This option is only used in the legacy retry mode.

    @see https://www.awsarchitectureblog.com/2015/03/backoff.html

  • :retry_limit (Integer) — default: 3

    The maximum number of times to retry failed requests. Only ~ 500 level server errors and certain ~ 400 level client errors are retried. Generally, these are throttling errors, data checksum errors, networking errors, timeout errors, auth errors, endpoint discovery, and errors from expired credentials. This option is only used in the legacy retry mode.

  • :retry_max_delay (Integer) — default: 0

    The maximum number of seconds to delay between retries (0 for no limit) used by the default backoff function. This option is only used in the legacy retry mode.

  • :retry_mode (String) — default: "legacy"

    Specifies which retry algorithm to use. Values are:

    • legacy - The pre-existing retry behavior. This is the default value if no retry mode is provided.

    • standard - A standardized set of retry rules across the AWS SDKs. This includes support for retry quotas, which limit the number of unsuccessful retries a client can make.

    • adaptive - A retry mode that includes all the functionality of standard mode along with automatic client side throttling.

  • :sdk_ua_app_id (String)

    A unique and opaque application ID that is appended to the User-Agent header as app/sdk_ua_app_id. It should have a maximum length of 50. This variable is sourced from environment variable AWS_SDK_UA_APP_ID or the shared config profile attribute sdk_ua_app_id.

  • :secret_access_key (String)
  • :session_token (String)
  • :sigv4a_signing_region_set (Array)

    A list of regions that should be signed with SigV4a signing. When not passed, a default :sigv4a_signing_region_set is searched for in the following locations:

    • Aws.config[:sigv4a_signing_region_set]
    • ENV['AWS_SIGV4A_SIGNING_REGION_SET']
    • ~/.aws/config
  • :stub_responses (Boolean) — default: false

    Causes the client to return stubbed responses. By default fake responses are generated and returned. You can specify the response data to return or errors to raise by calling ClientStubs#stub_responses. See ClientStubs for more information.

    Please note When response stubbing is enabled, no HTTP requests are made, and retries are disabled.

  • :telemetry_provider (Aws::Telemetry::TelemetryProviderBase) — default: Aws::Telemetry::NoOpTelemetryProvider

    Allows you to provide a telemetry provider, which is used to emit telemetry data. By default, uses NoOpTelemetryProvider which will not record or emit any telemetry data. The SDK supports the following telemetry providers:

    • OpenTelemetry (OTel) - To use the OTel provider, install and require the opentelemetry-sdk gem and then, pass in an instance of a Aws::Telemetry::OTelProvider for telemetry provider.
  • :token_provider (Aws::TokenProvider)

    Your Bearer token used for authentication. This can be any class that includes and implements Aws::TokenProvider, or instance of any one of the following classes:

    • Aws::StaticTokenProvider - Used for configuring static, non-refreshing tokens.

    • Aws::SSOTokenProvider - Used for loading tokens from AWS SSO using an access token generated from aws login.

    When :token_provider is not configured directly, the Aws::TokenProviderChain will be used to search for tokens configured for your profile in shared configuration files.

  • :use_dualstack_endpoint (Boolean)

    When set to true, dualstack enabled endpoints (with .aws TLD) will be used if available.

  • :use_fips_endpoint (Boolean)

    When set to true, fips compatible endpoints will be used if available. When a fips region is used, the region is normalized and this config is set to true.

  • :validate_params (Boolean) — default: true

    When true, request parameters are validated before sending the request.

  • :endpoint_provider (Aws::Resiliencehubv2::EndpointProvider)

    The endpoint provider used to resolve endpoints. Any object that responds to #resolve_endpoint(parameters) where parameters is a Struct similar to Aws::Resiliencehubv2::EndpointParameters.

  • :http_continue_timeout (Float) — default: 1

    The number of seconds to wait for a 100-continue response before sending the request body. This option has no effect unless the request has "Expect" header set to "100-continue". Defaults to nil which disables this behaviour. This value can safely be set per request on the session.

  • :http_idle_timeout (Float) — default: 5

    The number of seconds a connection is allowed to sit idle before it is considered stale. Stale connections are closed and removed from the pool before making a request.

  • :http_open_timeout (Float) — default: 15

    The default number of seconds to wait for response data. This value can safely be set per-request on the session.

  • :http_proxy (URI::HTTP, String)

    A proxy to send requests through. Formatted like 'http://proxy.com:123'.

  • :http_read_timeout (Float) — default: 60

    The default number of seconds to wait for response data. This value can safely be set per-request on the session.

  • :http_wire_trace (Boolean) — default: false

    When true, HTTP debug output will be sent to the :logger.

  • :on_chunk_received (Proc)

    When a Proc object is provided, it will be used as callback when each chunk of the response body is received. It provides three arguments: the chunk, the number of bytes received, and the total number of bytes in the response (or nil if the server did not send a content-length).

  • :on_chunk_sent (Proc)

    When a Proc object is provided, it will be used as callback when each chunk of the request body is sent. It provides three arguments: the chunk, the number of bytes read from the body, and the total number of bytes in the body.

  • :raise_response_errors (Boolean) — default: true

    When true, response errors are raised.

  • :ssl_ca_bundle (String)

    Full path to the SSL certificate authority bundle file that should be used when verifying peer certificates. If you do not pass :ssl_ca_bundle or :ssl_ca_directory the the system default will be used if available.

  • :ssl_ca_directory (String)

    Full path of the directory that contains the unbundled SSL certificate authority files for verifying peer certificates. If you do not pass :ssl_ca_bundle or :ssl_ca_directory the the system default will be used if available.

  • :ssl_ca_store (String)

    Sets the X509::Store to verify peer certificate.

  • :ssl_cert (OpenSSL::X509::Certificate)

    Sets a client certificate when creating http connections.

  • :ssl_key (OpenSSL::PKey)

    Sets a client key when creating http connections.

  • :ssl_timeout (Float)

    Sets the SSL timeout in seconds

  • :ssl_verify_peer (Boolean) — default: true

    When true, SSL peer certificates are verified when establishing a connection.



471
472
473
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 471

def initialize(*args)
  super
end

Instance Method Details

#create_assertion(params = {}) ⇒ Types::CreateAssertionResponse

Creates a resilience assertion for a service.

Examples:

Request syntax with placeholder values


resp = client.create_assertion({
  service_arn: "Arn", # required
  text: "AssertionText", # required
  client_token: "ClientToken",
})

Response structure


resp.assertion.service_arn #=> String
resp.assertion.assertion_id #=> String
resp.assertion.text #=> String
resp.assertion.source #=> String, one of "AI_GENERATED", "USER"
resp.assertion.created_at #=> Time
resp.assertion.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :text (required, String)

    The text content of the assertion.

  • :client_token (String)

    Idempotency token.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

Returns:

See Also:



516
517
518
519
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 516

def create_assertion(params = {}, options = {})
  req = build_request(:create_assertion, params)
  req.send_request(options)
end

#create_input_source(params = {}) ⇒ Types::CreateInputSourceResponse

Creates an input source for a service.

Examples:

Request syntax with placeholder values


resp = client.create_input_source({
  service_arn: "Arn", # required
  resource_configuration: { # required
    resource_tags: [
      {
        key: "TagKey", # required
        values: ["TagValue"], # required
      },
    ],
    cfn_stack_arn: "Arn",
    tf_state_file_url: "S3Url",
    eks: {
      cluster_arn: "Arn", # required
      namespaces: ["EksNamespace"], # required
      label_selector: {
        match_labels: {
          "EksLabelKey" => "EksLabelValue",
        },
        match_expressions: [
          {
            key: "EksLabelKey", # required
            operator: "IN", # required, accepts IN, NOT_IN, EXISTS, DOES_NOT_EXIST
            values: ["EksLabelValue"],
          },
        ],
      },
    },
    design_file_s3_url: "S3Url",
  },
  client_token: "ClientToken",
})

Response structure


resp.service_arn #=> String
resp.input_source_id #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :resource_configuration (required, Types::ResourceConfiguration)

    Resource configuration for an input source. Provide exactly one field.

  • :client_token (String)

    Idempotency token.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

Returns:

See Also:



583
584
585
586
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 583

def create_input_source(params = {}, options = {})
  req = build_request(:create_input_source, params)
  req.send_request(options)
end

#create_policy(params = {}) ⇒ Types::CreatePolicyResponse

Creates a resilience policy that defines availability and disaster recovery requirements.

Examples:

Request syntax with placeholder values


resp = client.create_policy({
  name: "EntityName", # required
  description: "LongDescription",
  availability_slo: {
    target: 1.0,
  },
  multi_az: {
    rto_in_minutes: 1,
    rpo_in_minutes: 1,
    disaster_recovery_approach: "ACTIVE_ACTIVE", # accepts ACTIVE_ACTIVE, HOT_STANDBY, WARM_STANDBY, PILOT_LIGHT, BACKUP_AND_RESTORE
  },
  multi_region: {
    rto_in_minutes: 1,
    rpo_in_minutes: 1,
    disaster_recovery_approach: "ACTIVE_ACTIVE", # accepts ACTIVE_ACTIVE, HOT_STANDBY, WARM_STANDBY, PILOT_LIGHT, BACKUP_AND_RESTORE
  },
  data_recovery: {
    time_between_backups_in_minutes: 1,
  },
  kms_key_id: "KmsKeyId",
  tags: {
    "TagKey" => "TagValue",
  },
  client_token: "ClientToken",
})

Response structure


resp.policy.policy_arn #=> String
resp.policy.name #=> String
resp.policy.description #=> String
resp.policy.availability_slo.target #=> Float
resp.policy.multi_az.rto_in_minutes #=> Integer
resp.policy.multi_az.rpo_in_minutes #=> Integer
resp.policy.multi_az.disaster_recovery_approach #=> String, one of "ACTIVE_ACTIVE", "HOT_STANDBY", "WARM_STANDBY", "PILOT_LIGHT", "BACKUP_AND_RESTORE"
resp.policy.multi_region.rto_in_minutes #=> Integer
resp.policy.multi_region.rpo_in_minutes #=> Integer
resp.policy.multi_region.disaster_recovery_approach #=> String, one of "ACTIVE_ACTIVE", "HOT_STANDBY", "WARM_STANDBY", "PILOT_LIGHT", "BACKUP_AND_RESTORE"
resp.policy.data_recovery.time_between_backups_in_minutes #=> Integer
resp.policy.kms_key_id #=> String
resp.policy.tags #=> Hash
resp.policy.tags["TagKey"] #=> String
resp.policy.associated_service_count #=> Integer
resp.policy.created_at #=> Time
resp.policy.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :name (required, String)

    Resource name (used in ARN — no spaces allowed).

  • :description (String)

    Resource description for services and policies.

  • :availability_slo (Types::AvailabilitySlo)

    The availability SLO for the resilience policy.

  • :multi_az (Types::MultiAzTargets)

    The multi-AZ disaster recovery targets for the resilience policy.

  • :multi_region (Types::MultiRegionTargets)

    The multi-Region disaster recovery targets for the resilience policy.

  • :data_recovery (Types::DataRecoveryTargets)

    The data recovery targets for the resilience policy.

  • :kms_key_id (String)

    KMS key identifier — accepts key ID, key ARN, alias name, or alias ARN.

  • :tags (Hash<String,String>)

    Resource tags.

  • :client_token (String)

    Idempotency token.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

Returns:

See Also:



678
679
680
681
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 678

def create_policy(params = {}, options = {})
  req = build_request(:create_policy, params)
  req.send_request(options)
end

#create_report(params = {}) ⇒ Types::CreateReportResponse

On-demand report creation. Idempotent — duplicate requests with same clientToken return existing result.

Examples:

Request syntax with placeholder values


resp = client.create_report({
  service_arn: "Arn", # required
  report_type: "FAILURE_MODE", # required, accepts FAILURE_MODE, TESTING
  client_token: "ClientToken",
})

Response structure


resp.report_generation_result.report_type #=> String, one of "FAILURE_MODE", "TESTING"
resp.report_generation_result.status #=> String, one of "PENDING", "SUCCEEDED", "FAILED"
resp.report_generation_result.service_arn #=> String
resp.report_generation_result.assessment_id #=> String
resp.report_generation_result.test_run_id #=> String
resp.report_generation_result.test_template_arn #=> String
resp.report_generation_result.created_at #=> Time
resp.report_generation_result.report_output.s3_report_output.s3_object_key #=> String
resp.report_generation_result.report_output.failed_report_output.error_code #=> String, one of "INSUFFICIENT_PERMISSIONS", "CONFIGURATION_ERROR", "INTERNAL_ERROR"
resp.report_generation_result.report_output.failed_report_output.error_message #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :report_type (required, String)

    The type of report to generate.

  • :client_token (String)

    Idempotency token.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

Returns:

See Also:



727
728
729
730
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 727

def create_report(params = {}, options = {})
  req = build_request(:create_report, params)
  req.send_request(options)
end

#create_service(params = {}) ⇒ Types::CreateServiceResponse

Creates a service.

Examples:

Request syntax with placeholder values


resp = client.create_service({
  name: "EntityName", # required
  description: "LongDescription",
  associated_systems: [
    {
      system_arn: "Arn", # required
      system_name: "EntityName",
      user_journey_ids: ["UserJourneyId"],
    },
  ],
  policy_arn: "Arn",
  regions: ["AwsRegion"], # required
  permission_model: { # required
    invoker_role_name: "IamRoleName", # required
    cross_account_roles: [
      {
        cross_account_role_arn: "IamRoleArn", # required
        external_id: "CrossAccountRoleExternalIdString",
      },
    ],
  },
  dependency_discovery: "ENABLED", # accepts ENABLED, DISABLED
  report_configuration: {
    report_outputs: [ # required
      {
        s3: {
          bucket_path: "S3BucketPath", # required
          bucket_owner: "AwsAccountId", # required
        },
      },
    ],
  },
  kms_key_id: "KmsKeyId",
  tags: {
    "TagKey" => "TagValue",
  },
  client_token: "ClientToken",
})

Response structure


resp.service.service_arn #=> String
resp.service.name #=> String
resp.service.description #=> String
resp.service.associated_systems #=> Array
resp.service.associated_systems[0].system_arn #=> String
resp.service.associated_systems[0].system_name #=> String
resp.service.associated_systems[0].user_journey_ids #=> Array
resp.service.associated_systems[0].user_journey_ids[0] #=> String
resp.service.policy_arn #=> String
resp.service.regions #=> Array
resp.service.regions[0] #=> String
resp.service.permission_model.invoker_role_name #=> String
resp.service.permission_model. #=> Array
resp.service.permission_model.[0]. #=> String
resp.service.permission_model.[0].external_id #=> String
resp.service.dependency_discovery.status #=> String, one of "ENABLED", "INITIALIZING", "DISABLED"
resp.service.dependency_discovery.updated_at #=> Time
resp.service.dependency_discovery.eligible_resource_count #=> Integer
resp.service.dependency_discovery.message #=> String
resp.service.effective_policy_values.availability_slo.value #=> Float
resp.service.effective_policy_values.availability_slo.policy_name #=> String
resp.service.effective_policy_values.availability_slo.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_az_rto.value #=> Integer
resp.service.effective_policy_values.multi_az_rto.policy_name #=> String
resp.service.effective_policy_values.multi_az_rto.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_az_rpo.value #=> Integer
resp.service.effective_policy_values.multi_az_rpo.policy_name #=> String
resp.service.effective_policy_values.multi_az_rpo.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_az_dr_approach.value #=> String
resp.service.effective_policy_values.multi_az_dr_approach.policy_name #=> String
resp.service.effective_policy_values.multi_az_dr_approach.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_region_rto.value #=> Integer
resp.service.effective_policy_values.multi_region_rto.policy_name #=> String
resp.service.effective_policy_values.multi_region_rto.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_region_rpo.value #=> Integer
resp.service.effective_policy_values.multi_region_rpo.policy_name #=> String
resp.service.effective_policy_values.multi_region_rpo.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_region_dr_approach.value #=> String
resp.service.effective_policy_values.multi_region_dr_approach.policy_name #=> String
resp.service.effective_policy_values.multi_region_dr_approach.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.data_recovery_time_between_backups.value #=> Integer
resp.service.effective_policy_values.data_recovery_time_between_backups.policy_name #=> String
resp.service.effective_policy_values.data_recovery_time_between_backups.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.achievability.availability_slo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.achievability.multi_az_rto_rpo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.achievability.multi_region_rto_rpo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.achievability.data_recovery_time_between_backups #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.report_configuration.report_outputs #=> Array
resp.service.report_configuration.report_outputs[0].s3.bucket_path #=> String
resp.service.report_configuration.report_outputs[0].s3.bucket_owner #=> String
resp.service.kms_key_id #=> String
resp.service.tags #=> Hash
resp.service.tags["TagKey"] #=> String
resp.service.estimated_assessment_cost.amount #=> Float
resp.service.estimated_assessment_cost.currency #=> String, one of "USD"
resp.service.resource_discovery.status #=> String, one of "RUNNING", "SUCCEEDED", "FAILED", "COMPLETED_WITH_FAILURES", "NOT_STARTED"
resp.service.resource_discovery.last_run_at #=> Time
resp.service.resource_discovery.error_code #=> String, one of "INVALID_PERMISSIONS", "STACK_NOT_FOUND", "CLUSTER_NOT_FOUND", "STATE_FILE_NOT_FOUND", "ACCESS_DENIED", "UNSUPPORTED_CLUSTER", "INTERNAL_ERROR"
resp.service.resource_discovery.error_message #=> String
resp.service.assessment_status #=> String, one of "NOT_STARTED", "PENDING", "IN_PROGRESS", "FAILED", "SUCCESS"
resp.service.rerun_assessment #=> Boolean
resp.service.open_findings_count #=> Integer
resp.service.resolved_findings_count #=> Integer
resp.service.organization_id #=> String
resp.service.ou_id #=> String
resp.service. #=> String
resp.service.created_at #=> Time
resp.service.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :name (required, String)

    Resource name (used in ARN — no spaces allowed).

  • :description (String)

    Resource description for services and policies.

  • :associated_systems (Array<Types::AssociatedSystem>)

    The systems to associate with the service.

  • :policy_arn (String)

    ARN identifier.

  • :regions (required, Array<String>)

    The Regions where the service operates.

  • :permission_model (required, Types::PermissionModel)

    The permission model for the service.

  • :dependency_discovery (String)

    Caller-settable values for dependency discovery. INITIALIZING is system-managed.

  • :report_configuration (Types::ServiceReportConfiguration)

    Configuration for automatic report generation on a Service.

  • :kms_key_id (String)

    KMS key identifier — accepts key ID, key ARN, alias name, or alias ARN.

  • :tags (Hash<String,String>)

    Resource tags.

  • :client_token (String)

    Idempotency token.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

Returns:

See Also:



892
893
894
895
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 892

def create_service(params = {}, options = {})
  req = build_request(:create_service, params)
  req.send_request(options)
end

#create_service_function(params = {}) ⇒ Types::CreateServiceFunctionResponse

Creates a service function within a service.

Examples:

Request syntax with placeholder values


resp = client.create_service_function({
  name: "EntityLabel", # required
  service_arn: "Arn", # required
  description: "EntityDescription",
  criticality: "PRIMARY", # required, accepts PRIMARY, SUPPLEMENTAL
  client_token: "ClientToken",
})

Response structure


resp.service_function.service_arn #=> String
resp.service_function.service_function_id #=> String
resp.service_function.name #=> String
resp.service_function.description #=> String
resp.service_function.criticality #=> String, one of "PRIMARY", "SUPPLEMENTAL"
resp.service_function.resource_count #=> Integer
resp.service_function.source #=> String, one of "AI_GENERATED", "USER"
resp.service_function.created_at #=> Time
resp.service_function.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :name (required, String)

    Entity label (not part of ARN — spaces allowed).

  • :service_arn (required, String)

    ARN identifier.

  • :description (String)

    Resource description.

  • :criticality (required, String)

    The criticality level of the service function.

  • :client_token (String)

    Idempotency token.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

Returns:

See Also:



947
948
949
950
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 947

def create_service_function(params = {}, options = {})
  req = build_request(:create_service_function, params)
  req.send_request(options)
end

#create_service_function_resources(params = {}) ⇒ Types::CreateServiceFunctionResourcesResponse

Associates resources with a service function.

Examples:

Request syntax with placeholder values


resp = client.create_service_function_resources({
  service_arn: "Arn", # required
  service_function_id: "EntityId", # required
  resources: ["String"], # required
})

Response structure


resp.service_arn #=> String
resp.service_function_id #=> String
resp.resources #=> Array
resp.resources[0] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :service_function_id (required, String)

    The identifier of the service function to associate resources with.

  • :resources (required, Array<String>)

    The list of resources to associate with the service function.

Returns:

See Also:



988
989
990
991
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 988

def create_service_function_resources(params = {}, options = {})
  req = build_request(:create_service_function_resources, params)
  req.send_request(options)
end

#create_system(params = {}) ⇒ Types::CreateSystemResponse

Creates a system that represents a logical grouping of services.

Examples:

Request syntax with placeholder values


resp = client.create_system({
  name: "EntityName", # required
  description: "EntityDescription",
  sharing_enabled: false,
  kms_key_id: "KmsKeyId",
  tags: {
    "TagKey" => "TagValue",
  },
  client_token: "ClientToken",
})

Response structure


resp.system.system_arn #=> String
resp.system.system_id #=> String
resp.system.name #=> String
resp.system.description #=> String
resp.system.sharing_enabled #=> Boolean
resp.system.tags #=> Hash
resp.system.tags["TagKey"] #=> String
resp.system.kms_key_id #=> String
resp.system.organization_id #=> String
resp.system.ou_id #=> String
resp.system.created_at #=> Time
resp.system.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :name (required, String)

    Resource name (used in ARN — no spaces allowed).

  • :description (String)

    Resource description.

  • :sharing_enabled (Boolean)

    Indicates whether cross-account sharing is enabled for the system.

  • :kms_key_id (String)

    KMS key identifier — accepts key ID, key ARN, alias name, or alias ARN.

  • :tags (Hash<String,String>)

    Resource tags.

  • :client_token (String)

    Idempotency token.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

Returns:

See Also:



1053
1054
1055
1056
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1053

def create_system(params = {}, options = {})
  req = build_request(:create_system, params)
  req.send_request(options)
end

#create_test(params = {}) ⇒ Types::CreateTestResponse

Creates a test for a service by configuring a test template. Each service has one test per template.

Examples:

Request syntax with placeholder values


resp = client.create_test({
  service_arn: "Arn", # required
  test_template_arn: "ServiceOwnedArn", # required
  logging_configuration: {
    s3_bucket_name: "String",
    cloud_watch_log_group_arn: "Arn",
    log_schema_version: "String",
  },
  stop_conditions: [
    {
      source: "aws:cloudwatch:alarm", # required, accepts aws:cloudwatch:alarm, none
      value: "String", # required
    },
  ],
  role_name: "IamRoleName",
  parameters: {
    "ParameterKey" => ["ParameterValue"],
  },
})

Response structure


resp.test.test_id #=> String
resp.test.test_template_arn #=> String
resp.test.service_arn #=> String
resp.test.name #=> String
resp.test.actions #=> Array
resp.test.actions[0].action_id #=> String
resp.test.actions[0].description #=> String
resp.test.actions[0].resource_type #=> String
resp.test.logging_configuration.s3_bucket_name #=> String
resp.test.logging_configuration.cloud_watch_log_group_arn #=> String
resp.test.logging_configuration.log_schema_version #=> String
resp.test.stop_conditions #=> Array
resp.test.stop_conditions[0].source #=> String, one of "aws:cloudwatch:alarm", "none"
resp.test.stop_conditions[0].value #=> String
resp.test.role_name #=> String
resp.test.parameters #=> Hash
resp.test.parameters["ParameterKey"] #=> Array
resp.test.parameters["ParameterKey"][0] #=> String
resp.test.total_test_runs #=> Integer
resp.test.successful_test_runs #=> Integer
resp.test.creation_time #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    The ARN of the service to create the test for.

  • :test_template_arn (required, String)

    The ARN of the test template to configure.

  • :logging_configuration (Types::LoggingConfiguration)

    The logging configuration for the test.

  • :stop_conditions (Array<Types::StopCondition>)

    The stop conditions for the test.

  • :role_name (String)

    The name of the IAM execution role to use when running the test.

  • :parameters (Hash<String,Array>)

    The parameter values for the test.

Returns:

See Also:



1133
1134
1135
1136
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1133

def create_test(params = {}, options = {})
  req = build_request(:create_test, params)
  req.send_request(options)
end

#create_user_journey(params = {}) ⇒ Types::CreateUserJourneyResponse

Creates a user journey within a system.

Examples:

Request syntax with placeholder values


resp = client.create_user_journey({
  system_arn: "Arn", # required
  name: "EntityLabel", # required
  description: "EntityDescription",
  policy_arn: "Arn",
  client_token: "ClientToken",
})

Response structure


resp.user_journey.user_journey_id #=> String
resp.user_journey.name #=> String
resp.user_journey.description #=> String
resp.user_journey.policy_arn #=> String
resp.user_journey.created_at #=> Time
resp.user_journey.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :system_arn (required, String)

    ARN identifier.

  • :name (required, String)

    Entity label (not part of ARN — spaces allowed).

  • :description (String)

    Resource description.

  • :policy_arn (String)

    ARN identifier.

  • :client_token (String)

    Idempotency token.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

Returns:

See Also:



1185
1186
1187
1188
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1185

def create_user_journey(params = {}, options = {})
  req = build_request(:create_user_journey, params)
  req.send_request(options)
end

#delete_assertion(params = {}) ⇒ Types::DeleteAssertionResponse

Deletes a resilience assertion from a service.

Examples:

Request syntax with placeholder values


resp = client.delete_assertion({
  service_arn: "Arn", # required
  assertion_id: "Uuid", # required
})

Response structure


resp.assertion_id #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :assertion_id (required, String)

    The unique identifier of the assertion to delete.

Returns:

See Also:



1217
1218
1219
1220
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1217

def delete_assertion(params = {}, options = {})
  req = build_request(:delete_assertion, params)
  req.send_request(options)
end

#delete_input_source(params = {}) ⇒ Types::DeleteInputSourceResponse

Deletes an input source.

Examples:

Request syntax with placeholder values


resp = client.delete_input_source({
  service_arn: "Arn", # required
  input_source_id: "InputSourceId", # required
})

Response structure


resp.service_arn #=> String
resp.input_source_id #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :input_source_id (required, String)

    The identifier of the input source to delete.

Returns:

See Also:



1251
1252
1253
1254
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1251

def delete_input_source(params = {}, options = {})
  req = build_request(:delete_input_source, params)
  req.send_request(options)
end

#delete_policy(params = {}) ⇒ Types::DeletePolicyResponse

Deletes a resilience policy.

Examples:

Request syntax with placeholder values


resp = client.delete_policy({
  policy_arn: "Arn", # required
})

Response structure


resp.policy_arn #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :policy_arn (required, String)

    ARN identifier.

Returns:

See Also:



1279
1280
1281
1282
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1279

def delete_policy(params = {}, options = {})
  req = build_request(:delete_policy, params)
  req.send_request(options)
end

#delete_service(params = {}) ⇒ Types::DeleteServiceResponse

Deletes a service.

Examples:

Request syntax with placeholder values


resp = client.delete_service({
  service_arn: "Arn", # required
})

Response structure


resp.service_arn #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

Returns:

See Also:



1307
1308
1309
1310
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1307

def delete_service(params = {}, options = {})
  req = build_request(:delete_service, params)
  req.send_request(options)
end

#delete_service_function(params = {}) ⇒ Types::DeleteServiceFunctionResponse

Deletes a service function.

Examples:

Request syntax with placeholder values


resp = client.delete_service_function({
  service_arn: "Arn", # required
  service_function_id: "EntityId", # required
})

Response structure


resp.service_function_id #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :service_function_id (required, String)

    The identifier of the service function to delete.

Returns:

See Also:



1339
1340
1341
1342
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1339

def delete_service_function(params = {}, options = {})
  req = build_request(:delete_service_function, params)
  req.send_request(options)
end

#delete_service_function_resources(params = {}) ⇒ Types::DeleteServiceFunctionResourcesResponse

Removes resources from a service function.

Examples:

Request syntax with placeholder values


resp = client.delete_service_function_resources({
  service_arn: "Arn", # required
  service_function_id: "EntityId", # required
  resources: ["String"], # required
})

Response structure


resp.service_arn #=> String
resp.service_function_id #=> String
resp.resources #=> Array
resp.resources[0] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :service_function_id (required, String)

    The identifier of the service function to remove resources from.

  • :resources (required, Array<String>)

    The list of resources to remove from the service function.

Returns:

See Also:



1380
1381
1382
1383
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1380

def delete_service_function_resources(params = {}, options = {})
  req = build_request(:delete_service_function_resources, params)
  req.send_request(options)
end

#delete_system(params = {}) ⇒ Types::DeleteSystemResponse

Deletes a system.

Examples:

Request syntax with placeholder values


resp = client.delete_system({
  system_arn: "Arn", # required
})

Response structure


resp.system_arn #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :system_arn (required, String)

    ARN identifier.

Returns:

See Also:



1408
1409
1410
1411
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1408

def delete_system(params = {}, options = {})
  req = build_request(:delete_system, params)
  req.send_request(options)
end

#delete_test(params = {}) ⇒ Types::DeleteTestResponse

Deletes a test.

Examples:

Request syntax with placeholder values


resp = client.delete_test({
  test_id: "TestId", # required
  service_arn: "Arn", # required
})

Response structure


resp.test_id #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_id (required, String)

    The identifier of the test to delete.

  • :service_arn (required, String)

    The ARN of the service the test belongs to.

Returns:

See Also:



1440
1441
1442
1443
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1440

def delete_test(params = {}, options = {})
  req = build_request(:delete_test, params)
  req.send_request(options)
end

#delete_test_sources(params = {}) ⇒ Struct

Removes monitoring sources from a test. The operation is transactional and idempotent — removing a source that is not attached is a no-op.

Examples:

Request syntax with placeholder values


resp = client.delete_test_sources({
  test_id: "TestId", # required
  service_arn: "Arn", # required
  test_sources: [ # required
    {
      success_criteria_alarm: {
        alarm_arn: "CloudWatchAlarmArn", # required
      },
      observability_alarm: {
        alarm_arn: "CloudWatchAlarmArn", # required
      },
    },
  ],
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_id (required, String)

    The identifier of the test to remove sources from.

  • :service_arn (required, String)

    The ARN of the service the test belongs to.

  • :test_sources (required, Array<Types::TestSourceInput>)

    The monitoring sources to remove.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



1480
1481
1482
1483
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1480

def delete_test_sources(params = {}, options = {})
  req = build_request(:delete_test_sources, params)
  req.send_request(options)
end

#delete_user_journey(params = {}) ⇒ Types::DeleteUserJourneyResponse

Deletes a user journey.

Examples:

Request syntax with placeholder values


resp = client.delete_user_journey({
  system_arn: "Arn", # required
  user_journey_id: "UserJourneyId", # required
})

Response structure


resp.user_journey_id #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :system_arn (required, String)

    ARN identifier.

  • :user_journey_id (required, String)

    The identifier of the user journey to delete.

Returns:

See Also:



1512
1513
1514
1515
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1512

def delete_user_journey(params = {}, options = {})
  req = build_request(:delete_user_journey, params)
  req.send_request(options)
end

#get_failure_mode_finding(params = {}) ⇒ Types::GetFailureModeFindingResponse

Retrieves a finding by findingId.

Examples:

Request syntax with placeholder values


resp = client.get_failure_mode_finding({
  finding_id: "Uuid", # required
  service_arn: "Arn", # required
})

Response structure


resp.finding.finding_id #=> String
resp.finding.name #=> String
resp.finding.description #=> String
resp.finding.failure_category #=> String, one of "SHARED_FATE", "EXCESSIVE_LOAD", "EXCESSIVE_LATENCY", "MISCONFIGURATION_AND_BUGS", "SINGLE_POINT_OF_FAILURE"
resp.finding.status #=> String, one of "OPEN", "RESOLVED", "IRRELEVANT"
resp.finding.reasoning #=> String
resp.finding.comment #=> String
resp.finding.severity #=> String, one of "LOW", "MEDIUM", "HIGH"
resp.finding.service_functions #=> Array
resp.finding.service_functions[0] #=> String
resp.finding.policy_component #=> String, one of "AVAILABILITY_SLO", "MULTI_AZ_DISASTER_RECOVERY", "MULTI_REGION_DISASTER_RECOVERY", "DATA_RECOVERY"
resp.finding.infrastructure_and_code_recommendations #=> Array
resp.finding.infrastructure_and_code_recommendations[0].suggested_changes #=> Array
resp.finding.infrastructure_and_code_recommendations[0].suggested_changes[0] #=> String
resp.finding.observability_recommendations #=> Array
resp.finding.observability_recommendations[0].suggested_changes #=> Array
resp.finding.observability_recommendations[0].suggested_changes[0] #=> String
resp.finding.testing_recommendations #=> Array
resp.finding.testing_recommendations[0].suggested_changes #=> Array
resp.finding.testing_recommendations[0].suggested_changes[0] #=> String
resp.finding.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :finding_id (required, String)

    The unique identifier of the finding to retrieve.

  • :service_arn (required, String)

    ARN identifier.

Returns:

See Also:



1564
1565
1566
1567
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1564

def get_failure_mode_finding(params = {}, options = {})
  req = build_request(:get_failure_mode_finding, params)
  req.send_request(options)
end

#get_policy(params = {}) ⇒ Types::GetPolicyResponse

Retrieves a resilience policy by ARN.

Examples:

Request syntax with placeholder values


resp = client.get_policy({
  policy_arn: "Arn", # required
})

Response structure


resp.policy.policy_arn #=> String
resp.policy.name #=> String
resp.policy.description #=> String
resp.policy.availability_slo.target #=> Float
resp.policy.multi_az.rto_in_minutes #=> Integer
resp.policy.multi_az.rpo_in_minutes #=> Integer
resp.policy.multi_az.disaster_recovery_approach #=> String, one of "ACTIVE_ACTIVE", "HOT_STANDBY", "WARM_STANDBY", "PILOT_LIGHT", "BACKUP_AND_RESTORE"
resp.policy.multi_region.rto_in_minutes #=> Integer
resp.policy.multi_region.rpo_in_minutes #=> Integer
resp.policy.multi_region.disaster_recovery_approach #=> String, one of "ACTIVE_ACTIVE", "HOT_STANDBY", "WARM_STANDBY", "PILOT_LIGHT", "BACKUP_AND_RESTORE"
resp.policy.data_recovery.time_between_backups_in_minutes #=> Integer
resp.policy.kms_key_id #=> String
resp.policy.tags #=> Hash
resp.policy.tags["TagKey"] #=> String
resp.policy.associated_service_count #=> Integer
resp.policy.created_at #=> Time
resp.policy.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :policy_arn (required, String)

    ARN identifier.

Returns:

See Also:



1608
1609
1610
1611
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1608

def get_policy(params = {}, options = {})
  req = build_request(:get_policy, params)
  req.send_request(options)
end

#get_service(params = {}) ⇒ Types::GetServiceResponse

Retrieves a service by ARN.

The following waiters are defined for this operation (see #wait_until for detailed usage):

  • service_assessment_completed
  • service_resource_discovery_completed

Examples:

Request syntax with placeholder values


resp = client.get_service({
  service_arn: "Arn", # required
})

Response structure


resp.service.service_arn #=> String
resp.service.name #=> String
resp.service.description #=> String
resp.service.associated_systems #=> Array
resp.service.associated_systems[0].system_arn #=> String
resp.service.associated_systems[0].system_name #=> String
resp.service.associated_systems[0].user_journey_ids #=> Array
resp.service.associated_systems[0].user_journey_ids[0] #=> String
resp.service.policy_arn #=> String
resp.service.regions #=> Array
resp.service.regions[0] #=> String
resp.service.permission_model.invoker_role_name #=> String
resp.service.permission_model. #=> Array
resp.service.permission_model.[0]. #=> String
resp.service.permission_model.[0].external_id #=> String
resp.service.dependency_discovery.status #=> String, one of "ENABLED", "INITIALIZING", "DISABLED"
resp.service.dependency_discovery.updated_at #=> Time
resp.service.dependency_discovery.eligible_resource_count #=> Integer
resp.service.dependency_discovery.message #=> String
resp.service.effective_policy_values.availability_slo.value #=> Float
resp.service.effective_policy_values.availability_slo.policy_name #=> String
resp.service.effective_policy_values.availability_slo.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_az_rto.value #=> Integer
resp.service.effective_policy_values.multi_az_rto.policy_name #=> String
resp.service.effective_policy_values.multi_az_rto.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_az_rpo.value #=> Integer
resp.service.effective_policy_values.multi_az_rpo.policy_name #=> String
resp.service.effective_policy_values.multi_az_rpo.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_az_dr_approach.value #=> String
resp.service.effective_policy_values.multi_az_dr_approach.policy_name #=> String
resp.service.effective_policy_values.multi_az_dr_approach.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_region_rto.value #=> Integer
resp.service.effective_policy_values.multi_region_rto.policy_name #=> String
resp.service.effective_policy_values.multi_region_rto.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_region_rpo.value #=> Integer
resp.service.effective_policy_values.multi_region_rpo.policy_name #=> String
resp.service.effective_policy_values.multi_region_rpo.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_region_dr_approach.value #=> String
resp.service.effective_policy_values.multi_region_dr_approach.policy_name #=> String
resp.service.effective_policy_values.multi_region_dr_approach.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.data_recovery_time_between_backups.value #=> Integer
resp.service.effective_policy_values.data_recovery_time_between_backups.policy_name #=> String
resp.service.effective_policy_values.data_recovery_time_between_backups.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.achievability.availability_slo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.achievability.multi_az_rto_rpo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.achievability.multi_region_rto_rpo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.achievability.data_recovery_time_between_backups #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.report_configuration.report_outputs #=> Array
resp.service.report_configuration.report_outputs[0].s3.bucket_path #=> String
resp.service.report_configuration.report_outputs[0].s3.bucket_owner #=> String
resp.service.kms_key_id #=> String
resp.service.tags #=> Hash
resp.service.tags["TagKey"] #=> String
resp.service.estimated_assessment_cost.amount #=> Float
resp.service.estimated_assessment_cost.currency #=> String, one of "USD"
resp.service.resource_discovery.status #=> String, one of "RUNNING", "SUCCEEDED", "FAILED", "COMPLETED_WITH_FAILURES", "NOT_STARTED"
resp.service.resource_discovery.last_run_at #=> Time
resp.service.resource_discovery.error_code #=> String, one of "INVALID_PERMISSIONS", "STACK_NOT_FOUND", "CLUSTER_NOT_FOUND", "STATE_FILE_NOT_FOUND", "ACCESS_DENIED", "UNSUPPORTED_CLUSTER", "INTERNAL_ERROR"
resp.service.resource_discovery.error_message #=> String
resp.service.assessment_status #=> String, one of "NOT_STARTED", "PENDING", "IN_PROGRESS", "FAILED", "SUCCESS"
resp.service.rerun_assessment #=> Boolean
resp.service.open_findings_count #=> Integer
resp.service.resolved_findings_count #=> Integer
resp.service.organization_id #=> String
resp.service.ou_id #=> String
resp.service. #=> String
resp.service.created_at #=> Time
resp.service.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

Returns:

See Also:



1709
1710
1711
1712
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1709

def get_service(params = {}, options = {})
  req = build_request(:get_service, params)
  req.send_request(options)
end

#get_system(params = {}) ⇒ Types::GetSystemResponse

Retrieves a system by ARN.

Examples:

Request syntax with placeholder values


resp = client.get_system({
  system_arn: "Arn", # required
})

Response structure


resp.system.system_arn #=> String
resp.system.system_id #=> String
resp.system.name #=> String
resp.system.description #=> String
resp.system.sharing_enabled #=> Boolean
resp.system.tags #=> Hash
resp.system.tags["TagKey"] #=> String
resp.system.kms_key_id #=> String
resp.system.organization_id #=> String
resp.system.ou_id #=> String
resp.system.created_at #=> Time
resp.system.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :system_arn (required, String)

    ARN identifier.

Returns:

See Also:



1748
1749
1750
1751
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1748

def get_system(params = {}, options = {})
  req = build_request(:get_system, params)
  req.send_request(options)
end

#get_test(params = {}) ⇒ Types::GetTestResponse

Retrieves a test by ID.

Examples:

Request syntax with placeholder values


resp = client.get_test({
  test_id: "TestId", # required
  service_arn: "Arn", # required
})

Response structure


resp.test.test_id #=> String
resp.test.test_template_arn #=> String
resp.test.service_arn #=> String
resp.test.name #=> String
resp.test.actions #=> Array
resp.test.actions[0].action_id #=> String
resp.test.actions[0].description #=> String
resp.test.actions[0].resource_type #=> String
resp.test.logging_configuration.s3_bucket_name #=> String
resp.test.logging_configuration.cloud_watch_log_group_arn #=> String
resp.test.logging_configuration.log_schema_version #=> String
resp.test.stop_conditions #=> Array
resp.test.stop_conditions[0].source #=> String, one of "aws:cloudwatch:alarm", "none"
resp.test.stop_conditions[0].value #=> String
resp.test.role_name #=> String
resp.test.parameters #=> Hash
resp.test.parameters["ParameterKey"] #=> Array
resp.test.parameters["ParameterKey"][0] #=> String
resp.test.total_test_runs #=> Integer
resp.test.successful_test_runs #=> Integer
resp.test.creation_time #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_id (required, String)

    The identifier of the test to retrieve.

  • :service_arn (required, String)

    The ARN of the service the test belongs to.

Returns:

See Also:



1800
1801
1802
1803
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1800

def get_test(params = {}, options = {})
  req = build_request(:get_test, params)
  req.send_request(options)
end

#get_test_run(params = {}) ⇒ Types::GetTestRunResponse

Retrieves a test run by ID, including its status, results, and the configuration snapshotted when the run started.

Examples:

Request syntax with placeholder values


resp = client.get_test_run({
  test_run_id: "TestRunId", # required
  service_arn: "Arn", # required
})

Response structure


resp.test_run.test_run_id #=> String
resp.test_run.test_id #=> String
resp.test_run.status #=> String, one of "INITIALIZING", "RUNNING", "STOPPING", "PASSED", "FAILED", "STOPPED", "ERROR"
resp.test_run.service_arn #=> String
resp.test_run.started_at #=> Time
resp.test_run.ended_at #=> Time
resp.test_run.experiments #=> Array
resp.test_run.experiments[0].experiment_arn #=> String
resp.test_run.experiments[0].details #=> String
resp.test_run.event_count #=> Integer
resp.test_run.parameters #=> Hash
resp.test_run.parameters["ParameterKey"] #=> Array
resp.test_run.parameters["ParameterKey"][0] #=> String
resp.test_run.error_message #=> String
resp.test_run.stop_conditions #=> Array
resp.test_run.stop_conditions[0].source #=> String, one of "aws:cloudwatch:alarm", "none"
resp.test_run.stop_conditions[0].value #=> String
resp.test_run.logging_configuration.s3_bucket_name #=> String
resp.test_run.logging_configuration.cloud_watch_log_group_arn #=> String
resp.test_run.logging_configuration.log_schema_version #=> String
resp.test_run.role_name #=> String
resp.test_run.test_template_arn #=> String
resp.test_run.report_configuration.report_output #=> Array
resp.test_run.report_configuration.report_output[0].s3.bucket_path #=> String
resp.test_run.report_configuration.report_output[0].s3.bucket_owner #=> String
resp.test_run.policy.policy_arn #=> String
resp.test_run.policy.name #=> String
resp.test_run.policy.availability_slo.target #=> Float
resp.test_run.policy.multi_az.rto_in_minutes #=> Integer
resp.test_run.policy.multi_az.rpo_in_minutes #=> Integer
resp.test_run.policy.multi_az.disaster_recovery_approach #=> String, one of "ACTIVE_ACTIVE", "HOT_STANDBY", "WARM_STANDBY", "PILOT_LIGHT", "BACKUP_AND_RESTORE"
resp.test_run.policy.multi_region.rto_in_minutes #=> Integer
resp.test_run.policy.multi_region.rpo_in_minutes #=> Integer
resp.test_run.policy.multi_region.disaster_recovery_approach #=> String, one of "ACTIVE_ACTIVE", "HOT_STANDBY", "WARM_STANDBY", "PILOT_LIGHT", "BACKUP_AND_RESTORE"
resp.test_run.policy.data_recovery.time_between_backups_in_minutes #=> Integer
resp.test_run.report_output.report_type #=> String, one of "FAILURE_MODE", "TESTING"
resp.test_run.report_output.status #=> String, one of "PENDING", "SUCCEEDED", "FAILED"
resp.test_run.report_output.service_arn #=> String
resp.test_run.report_output.assessment_id #=> String
resp.test_run.report_output.test_run_id #=> String
resp.test_run.report_output.test_template_arn #=> String
resp.test_run.report_output.created_at #=> Time
resp.test_run.report_output.report_output.s3_report_output.s3_object_key #=> String
resp.test_run.report_output.report_output.failed_report_output.error_code #=> String, one of "INSUFFICIENT_PERMISSIONS", "CONFIGURATION_ERROR", "INTERNAL_ERROR"
resp.test_run.report_output.report_output.failed_report_output.error_message #=> String
resp.test_run.region_switch_plan_arn #=> String
resp.test_run.region_switch_execution_id #=> String
resp.test_run.permission_model.invoker_role_name #=> String
resp.test_run.permission_model. #=> Array
resp.test_run.permission_model.[0]. #=> String
resp.test_run.permission_model.[0].external_id #=> String
resp.test_run.regions #=> Array
resp.test_run.regions[0] #=> String
resp.test_run. #=> String, one of "SINGLE_ACCOUNT", "MULTI_ACCOUNT"

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_run_id (required, String)

    The identifier of the test run to retrieve.

  • :service_arn (required, String)

    The ARN of the service the test run belongs to.

Returns:

See Also:



1886
1887
1888
1889
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1886

def get_test_run(params = {}, options = {})
  req = build_request(:get_test_run, params)
  req.send_request(options)
end

#get_test_template(params = {}) ⇒ Types::GetTestTemplateResponse

Retrieves a resilience test template by ARN, including the parameters it accepts and the fault actions it runs.

Examples:

Request syntax with placeholder values


resp = client.get_test_template({
  test_template_arn: "ServiceOwnedArn", # required
})

Response structure


resp.test_template.test_template_arn #=> String
resp.test_template.name #=> String
resp.test_template.description #=> String
resp.test_template.parameters #=> Array
resp.test_template.parameters[0].name #=> String
resp.test_template.parameters[0].description #=> String
resp.test_template.parameters[0].type #=> String, one of "STRING", "STRING_LIST", "INTEGER"
resp.test_template.parameters[0].required #=> Boolean
resp.test_template.parameters[0].default_value #=> String
resp.test_template.parameters[0].max_values #=> Integer
resp.test_template.actions #=> Array
resp.test_template.actions[0].action_id #=> String
resp.test_template.actions[0].description #=> String
resp.test_template.actions[0].resource_type #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_template_arn (required, String)

    The ARN of the test template to retrieve.

Returns:

See Also:



1928
1929
1930
1931
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1928

def get_test_template(params = {}, options = {})
  req = build_request(:get_test_template, params)
  req.send_request(options)
end

#get_user_journey(params = {}) ⇒ Types::GetUserJourneyResponse

Retrieves a user journey.

Examples:

Request syntax with placeholder values


resp = client.get_user_journey({
  system_arn: "Arn", # required
  user_journey_id: "UserJourneyId", # required
})

Response structure


resp.user_journey.user_journey_id #=> String
resp.user_journey.name #=> String
resp.user_journey.description #=> String
resp.user_journey.policy_arn #=> String
resp.user_journey.created_at #=> Time
resp.user_journey.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :system_arn (required, String)

    ARN identifier.

  • :user_journey_id (required, String)

    The identifier of the user journey to retrieve.

Returns:

See Also:



1965
1966
1967
1968
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 1965

def get_user_journey(params = {}, options = {})
  req = build_request(:get_user_journey, params)
  req.send_request(options)
end

#import_app(params = {}) ⇒ Types::ImportAppResponse

Imports a V1 app into the V2 resource model, creating a service with the same name.

Examples:

Request syntax with placeholder values


resp = client.import_app({
  v1_app_arn: "Arn", # required
  policy_arn: "Arn",
  kms_key_id: "KmsKeyId",
  skip_manually_added_resources: false,
  associated_systems: [
    {
      system_arn: "Arn", # required
      system_name: "EntityName",
      user_journey_ids: ["UserJourneyId"],
    },
  ],
  tags: {
    "TagKey" => "TagValue",
  },
  client_token: "ClientToken",
})

Response structure


resp.service.service_arn #=> String
resp.service.name #=> String
resp.service.description #=> String
resp.service.associated_systems #=> Array
resp.service.associated_systems[0].system_arn #=> String
resp.service.associated_systems[0].system_name #=> String
resp.service.associated_systems[0].user_journey_ids #=> Array
resp.service.associated_systems[0].user_journey_ids[0] #=> String
resp.service.policy_arn #=> String
resp.service.regions #=> Array
resp.service.regions[0] #=> String
resp.service.permission_model.invoker_role_name #=> String
resp.service.permission_model. #=> Array
resp.service.permission_model.[0]. #=> String
resp.service.permission_model.[0].external_id #=> String
resp.service.dependency_discovery.status #=> String, one of "ENABLED", "INITIALIZING", "DISABLED"
resp.service.dependency_discovery.updated_at #=> Time
resp.service.dependency_discovery.eligible_resource_count #=> Integer
resp.service.dependency_discovery.message #=> String
resp.service.effective_policy_values.availability_slo.value #=> Float
resp.service.effective_policy_values.availability_slo.policy_name #=> String
resp.service.effective_policy_values.availability_slo.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_az_rto.value #=> Integer
resp.service.effective_policy_values.multi_az_rto.policy_name #=> String
resp.service.effective_policy_values.multi_az_rto.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_az_rpo.value #=> Integer
resp.service.effective_policy_values.multi_az_rpo.policy_name #=> String
resp.service.effective_policy_values.multi_az_rpo.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_az_dr_approach.value #=> String
resp.service.effective_policy_values.multi_az_dr_approach.policy_name #=> String
resp.service.effective_policy_values.multi_az_dr_approach.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_region_rto.value #=> Integer
resp.service.effective_policy_values.multi_region_rto.policy_name #=> String
resp.service.effective_policy_values.multi_region_rto.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_region_rpo.value #=> Integer
resp.service.effective_policy_values.multi_region_rpo.policy_name #=> String
resp.service.effective_policy_values.multi_region_rpo.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_region_dr_approach.value #=> String
resp.service.effective_policy_values.multi_region_dr_approach.policy_name #=> String
resp.service.effective_policy_values.multi_region_dr_approach.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.data_recovery_time_between_backups.value #=> Integer
resp.service.effective_policy_values.data_recovery_time_between_backups.policy_name #=> String
resp.service.effective_policy_values.data_recovery_time_between_backups.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.achievability.availability_slo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.achievability.multi_az_rto_rpo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.achievability.multi_region_rto_rpo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.achievability.data_recovery_time_between_backups #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.report_configuration.report_outputs #=> Array
resp.service.report_configuration.report_outputs[0].s3.bucket_path #=> String
resp.service.report_configuration.report_outputs[0].s3.bucket_owner #=> String
resp.service.kms_key_id #=> String
resp.service.tags #=> Hash
resp.service.tags["TagKey"] #=> String
resp.service.estimated_assessment_cost.amount #=> Float
resp.service.estimated_assessment_cost.currency #=> String, one of "USD"
resp.service.resource_discovery.status #=> String, one of "RUNNING", "SUCCEEDED", "FAILED", "COMPLETED_WITH_FAILURES", "NOT_STARTED"
resp.service.resource_discovery.last_run_at #=> Time
resp.service.resource_discovery.error_code #=> String, one of "INVALID_PERMISSIONS", "STACK_NOT_FOUND", "CLUSTER_NOT_FOUND", "STATE_FILE_NOT_FOUND", "ACCESS_DENIED", "UNSUPPORTED_CLUSTER", "INTERNAL_ERROR"
resp.service.resource_discovery.error_message #=> String
resp.service.assessment_status #=> String, one of "NOT_STARTED", "PENDING", "IN_PROGRESS", "FAILED", "SUCCESS"
resp.service.rerun_assessment #=> Boolean
resp.service.open_findings_count #=> Integer
resp.service.resolved_findings_count #=> Integer
resp.service.organization_id #=> String
resp.service.ou_id #=> String
resp.service. #=> String
resp.service.created_at #=> Time
resp.service.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :v1_app_arn (required, String)

    ARN identifier.

  • :policy_arn (String)

    ARN identifier.

  • :kms_key_id (String)

    KMS key identifier — accepts key ID, key ARN, alias name, or alias ARN.

  • :skip_manually_added_resources (Boolean)

    Whether to skip manually added resources during import.

  • :associated_systems (Array<Types::AssociatedSystem>)

    The systems to associate with the imported service.

  • :tags (Hash<String,String>)

    Resource tags.

  • :client_token (String)

    Idempotency token.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

Returns:

See Also:



2097
2098
2099
2100
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2097

def import_app(params = {}, options = {})
  req = build_request(:import_app, params)
  req.send_request(options)
end

#import_policy(params = {}) ⇒ Types::ImportPolicyResponse

Imports a V1 policy into V2, mapping RTO/RPO values from V1 scenarios.

Examples:

Request syntax with placeholder values


resp = client.import_policy({
  v1_policy_arn: "Arn", # required
  kms_key_id: "KmsKeyId",
  availability_slo: {
    target: 1.0,
  },
  multi_az_disaster_recovery_approach: "ACTIVE_ACTIVE", # accepts ACTIVE_ACTIVE, HOT_STANDBY, WARM_STANDBY, PILOT_LIGHT, BACKUP_AND_RESTORE
  multi_region_disaster_recovery_approach: "ACTIVE_ACTIVE", # accepts ACTIVE_ACTIVE, HOT_STANDBY, WARM_STANDBY, PILOT_LIGHT, BACKUP_AND_RESTORE
  tags: {
    "TagKey" => "TagValue",
  },
  client_token: "ClientToken",
})

Response structure


resp.policy.policy_arn #=> String
resp.policy.name #=> String
resp.policy.description #=> String
resp.policy.availability_slo.target #=> Float
resp.policy.multi_az.rto_in_minutes #=> Integer
resp.policy.multi_az.rpo_in_minutes #=> Integer
resp.policy.multi_az.disaster_recovery_approach #=> String, one of "ACTIVE_ACTIVE", "HOT_STANDBY", "WARM_STANDBY", "PILOT_LIGHT", "BACKUP_AND_RESTORE"
resp.policy.multi_region.rto_in_minutes #=> Integer
resp.policy.multi_region.rpo_in_minutes #=> Integer
resp.policy.multi_region.disaster_recovery_approach #=> String, one of "ACTIVE_ACTIVE", "HOT_STANDBY", "WARM_STANDBY", "PILOT_LIGHT", "BACKUP_AND_RESTORE"
resp.policy.data_recovery.time_between_backups_in_minutes #=> Integer
resp.policy.kms_key_id #=> String
resp.policy.tags #=> Hash
resp.policy.tags["TagKey"] #=> String
resp.policy.associated_service_count #=> Integer
resp.policy.created_at #=> Time
resp.policy.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :v1_policy_arn (required, String)

    ARN identifier.

  • :kms_key_id (String)

    KMS key identifier — accepts key ID, key ARN, alias name, or alias ARN.

  • :availability_slo (Types::AvailabilitySlo)

    The availability SLO to set on the imported policy.

  • :multi_az_disaster_recovery_approach (String)

    The multi-AZ disaster recovery approach for the imported policy.

  • :multi_region_disaster_recovery_approach (String)

    The multi-Region disaster recovery approach for the imported policy.

  • :tags (Hash<String,String>)

    Resource tags.

  • :client_token (String)

    Idempotency token.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

Returns:

See Also:



2173
2174
2175
2176
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2173

def import_policy(params = {}, options = {})
  req = build_request(:import_policy, params)
  req.send_request(options)
end

#list_assertions(params = {}) ⇒ Types::ListAssertionsResponse

Lists resilience assertions for a service.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_assertions({
  service_arn: "Arn", # required
  source: "AI_GENERATED", # accepts AI_GENERATED, USER
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.assertions #=> Array
resp.assertions[0].service_arn #=> String
resp.assertions[0].assertion_id #=> String
resp.assertions[0].text #=> String
resp.assertions[0].source #=> String, one of "AI_GENERATED", "USER"
resp.assertions[0].created_at #=> Time
resp.assertions[0].updated_at #=> Time
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :source (String)

    Filter assertions by source type.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



2223
2224
2225
2226
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2223

def list_assertions(params = {}, options = {})
  req = build_request(:list_assertions, params)
  req.send_request(options)
end

#list_dependencies(params = {}) ⇒ Types::ListDependenciesResponse

Lists dependencies discovered for services.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_dependencies({
  service_arn: "Arn",
  query_range_start_time: Time.now,
  query_range_end_time: Time.now,
  query_range_granularity: "HOURLY", # accepts HOURLY, DAILY
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.dependency_summaries #=> Array
resp.dependency_summaries[0].dependency_id #=> String
resp.dependency_summaries[0].service_arn #=> String
resp.dependency_summaries[0].dependency_name #=> String
resp.dependency_summaries[0].dns_name #=> String
resp.dependency_summaries[0].location #=> String
resp.dependency_summaries[0].last_detected_time #=> Time
resp.dependency_summaries[0].source_regions #=> Array
resp.dependency_summaries[0].source_regions[0] #=> String
resp.dependency_summaries[0].provider #=> String
resp.dependency_summaries[0].query_range.start_time #=> Time
resp.dependency_summaries[0].query_range.end_time #=> Time
resp.dependency_summaries[0].query_range.granularity #=> String, one of "HOURLY", "DAILY"
resp.dependency_summaries[0].query_range.data_points #=> Array
resp.dependency_summaries[0].query_range.data_points[0].timestamp #=> Time
resp.dependency_summaries[0].query_range.data_points[0].query_count #=> Integer
resp.dependency_summaries[0].criticality #=> String, one of "HARD", "SOFT", "UNKNOWN"
resp.dependency_summaries[0].comment #=> String
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (String)

    ARN identifier.

  • :query_range_start_time (Time, DateTime, Date, Integer, String)

    The start time for the dependency query range.

  • :query_range_end_time (Time, DateTime, Date, Integer, String)

    The end time for the dependency query range.

  • :query_range_granularity (String)

    The granularity for the dependency query range.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



2292
2293
2294
2295
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2292

def list_dependencies(params = {}, options = {})
  req = build_request(:list_dependencies, params)
  req.send_request(options)
end

#list_failure_mode_assessments(params = {}) ⇒ Types::ListFailureModeAssessmentsResponse

Lists failure mode assessments.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

The following waiters are defined for this operation (see #wait_until for detailed usage):

  • failure_mode_assessment_success

Examples:

Request syntax with placeholder values


resp = client.list_failure_mode_assessments({
  service_arn: "Arn", # required
  assessment_statuses: ["NOT_STARTED"], # accepts NOT_STARTED, PENDING, IN_PROGRESS, FAILED, SUCCESS
  started_after: Time.now,
  ended_before: Time.now,
  sort_by: "STARTED_AT", # accepts STARTED_AT
  sort_order: "ASC", # accepts ASC, DESC
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.assessment_summaries #=> Array
resp.assessment_summaries[0].assessment_id #=> String
resp.assessment_summaries[0].service_arn #=> String
resp.assessment_summaries[0].assessment_status #=> String, one of "NOT_STARTED", "PENDING", "IN_PROGRESS", "FAILED", "SUCCESS"
resp.assessment_summaries[0].assessment_step #=> String, one of "TOPOLOGY_GENERATION", "INPUT_VALIDATION", "DESIGN_ANALYSIS", "TOPOLOGY_ENHANCEMENT", "SERVICE_FUNCTION_GENERATION", "POLICY_VALIDATION", "RESILIENCE_ASSESSMENT", "FAILURE_MODE_FINDINGS_CONSOLIDATION", "FAILURE_MODE_FINDINGS_ENRICHMENT"
resp.assessment_summaries[0].total_findings #=> Integer
resp.assessment_summaries[0].started_at #=> Time
resp.assessment_summaries[0].ended_at #=> Time
resp.assessment_summaries[0].error_message #=> String
resp.assessment_summaries[0].error_code #=> String, one of "INVALID_PERMISSIONS", "CMK_ACCESS_DENIED", "AGENT_ERROR", "INTERNAL_ERROR", "DESIGN_FILE_ACCESS_DENIED"
resp.assessment_summaries[0].assessment_cost.amount #=> Float
resp.assessment_summaries[0].assessment_cost.currency #=> String, one of "USD"
resp.assessment_summaries[0].billable_assessment_unit_count #=> Integer
resp.assessment_summaries[0].achievability.availability_slo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.assessment_summaries[0].achievability.multi_az_rto_rpo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.assessment_summaries[0].achievability.multi_region_rto_rpo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.assessment_summaries[0].achievability.data_recovery_time_between_backups #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :assessment_statuses (Array<String>)

    Specifies the assessment statuses to include in the results.

  • :started_after (Time, DateTime, Date, Integer, String)

    Specifies that only assessments that started at or after this timestamp appear in the results.

  • :ended_before (Time, DateTime, Date, Integer, String)

    Specifies that only assessments that ended at or before this timestamp appear in the results.

  • :sort_by (String)

    The field to use for sorting failure mode assessments.

  • :sort_order (String)

    The sort order for results.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



2375
2376
2377
2378
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2375

def list_failure_mode_assessments(params = {}, options = {})
  req = build_request(:list_failure_mode_assessments, params)
  req.send_request(options)
end

#list_failure_mode_findings(params = {}) ⇒ Types::ListFailureModeFindingsResponse

List findings.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_failure_mode_findings({
  service_arn: "Arn", # required
  severity: "LOW", # accepts LOW, MEDIUM, HIGH
  failure_category: "SHARED_FATE", # accepts SHARED_FATE, EXCESSIVE_LOAD, EXCESSIVE_LATENCY, MISCONFIGURATION_AND_BUGS, SINGLE_POINT_OF_FAILURE
  status: "OPEN", # accepts OPEN, RESOLVED, IRRELEVANT
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.findings_summary #=> Array
resp.findings_summary[0].service_arn #=> String
resp.findings_summary[0].finding_id #=> String
resp.findings_summary[0].name #=> String
resp.findings_summary[0].description #=> String
resp.findings_summary[0].failure_category #=> String, one of "SHARED_FATE", "EXCESSIVE_LOAD", "EXCESSIVE_LATENCY", "MISCONFIGURATION_AND_BUGS", "SINGLE_POINT_OF_FAILURE"
resp.findings_summary[0].severity #=> String, one of "LOW", "MEDIUM", "HIGH"
resp.findings_summary[0].status #=> String, one of "OPEN", "RESOLVED", "IRRELEVANT"
resp.findings_summary[0].policy_component #=> String, one of "AVAILABILITY_SLO", "MULTI_AZ_DISASTER_RECOVERY", "MULTI_REGION_DISASTER_RECOVERY", "DATA_RECOVERY"
resp.findings_summary[0].updated_at #=> Time
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :severity (String)

    Filter findings by severity.

  • :failure_category (String)

    Filter findings by failure category.

  • :status (String)

    Filter findings by status.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



2436
2437
2438
2439
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2436

def list_failure_mode_findings(params = {}, options = {})
  req = build_request(:list_failure_mode_findings, params)
  req.send_request(options)
end

#list_input_sources(params = {}) ⇒ Types::ListInputSourcesResponse

Lists input sources for a service.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_input_sources({
  service_arn: "Arn", # required
  type: "CFN_STACK", # accepts CFN_STACK, TAGS, EKS, TERRAFORM, DESIGN_FILE, MONITORING
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.input_source_summaries #=> Array
resp.input_source_summaries[0].input_source_id #=> String
resp.input_source_summaries[0].type #=> String, one of "CFN_STACK", "TAGS", "EKS", "TERRAFORM", "DESIGN_FILE", "MONITORING"
resp.input_source_summaries[0].resource_tags #=> Array
resp.input_source_summaries[0].resource_tags[0].key #=> String
resp.input_source_summaries[0].resource_tags[0].values #=> Array
resp.input_source_summaries[0].resource_tags[0].values[0] #=> String
resp.input_source_summaries[0].cfn_stack_arn #=> String
resp.input_source_summaries[0].tf_state_file_url #=> String
resp.input_source_summaries[0].eks.cluster_arn #=> String
resp.input_source_summaries[0].eks.namespaces #=> Array
resp.input_source_summaries[0].eks.namespaces[0] #=> String
resp.input_source_summaries[0].eks.label_selector.match_labels #=> Hash
resp.input_source_summaries[0].eks.label_selector.match_labels["EksLabelKey"] #=> String
resp.input_source_summaries[0].eks.label_selector.match_expressions #=> Array
resp.input_source_summaries[0].eks.label_selector.match_expressions[0].key #=> String
resp.input_source_summaries[0].eks.label_selector.match_expressions[0].operator #=> String, one of "IN", "NOT_IN", "EXISTS", "DOES_NOT_EXIST"
resp.input_source_summaries[0].eks.label_selector.match_expressions[0].values #=> Array
resp.input_source_summaries[0].eks.label_selector.match_expressions[0].values[0] #=> String
resp.input_source_summaries[0].design_file_s3_url #=> String
resp.input_source_summaries[0].created_at #=> Time
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :type (String)

    Filter input sources by type.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



2500
2501
2502
2503
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2500

def list_input_sources(params = {}, options = {})
  req = build_request(:list_input_sources, params)
  req.send_request(options)
end

#list_policies(params = {}) ⇒ Types::ListPoliciesResponse

Lists resilience policies.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_policies({
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.policy_summaries #=> Array
resp.policy_summaries[0].policy_arn #=> String
resp.policy_summaries[0].name #=> String
resp.policy_summaries[0].availability_slo.target #=> Float
resp.policy_summaries[0].multi_az.rto_in_minutes #=> Integer
resp.policy_summaries[0].multi_az.rpo_in_minutes #=> Integer
resp.policy_summaries[0].multi_az.disaster_recovery_approach #=> String, one of "ACTIVE_ACTIVE", "HOT_STANDBY", "WARM_STANDBY", "PILOT_LIGHT", "BACKUP_AND_RESTORE"
resp.policy_summaries[0].multi_region.rto_in_minutes #=> Integer
resp.policy_summaries[0].multi_region.rpo_in_minutes #=> Integer
resp.policy_summaries[0].multi_region.disaster_recovery_approach #=> String, one of "ACTIVE_ACTIVE", "HOT_STANDBY", "WARM_STANDBY", "PILOT_LIGHT", "BACKUP_AND_RESTORE"
resp.policy_summaries[0].data_recovery.time_between_backups_in_minutes #=> Integer
resp.policy_summaries[0].associated_service_count #=> Integer
resp.policy_summaries[0].created_at #=> Time
resp.policy_summaries[0].updated_at #=> Time
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



2549
2550
2551
2552
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2549

def list_policies(params = {}, options = {})
  req = build_request(:list_policies, params)
  req.send_request(options)
end

#list_reports(params = {}) ⇒ Types::ListReportsResponse

List reports for a service, or all reports owned by the account if serviceArn is not provided.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

The following waiters are defined for this operation (see #wait_until for detailed usage):

  • report_succeeded

Examples:

Request syntax with placeholder values


resp = client.list_reports({
  service_arn: "Arn",
  report_type: "FAILURE_MODE", # accepts FAILURE_MODE, TESTING
  test_run_id: "TestRunId",
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.report_generation_results #=> Array
resp.report_generation_results[0].report_type #=> String, one of "FAILURE_MODE", "TESTING"
resp.report_generation_results[0].status #=> String, one of "PENDING", "SUCCEEDED", "FAILED"
resp.report_generation_results[0].service_arn #=> String
resp.report_generation_results[0].assessment_id #=> String
resp.report_generation_results[0].test_run_id #=> String
resp.report_generation_results[0].test_template_arn #=> String
resp.report_generation_results[0].created_at #=> Time
resp.report_generation_results[0].report_output.s3_report_output.s3_object_key #=> String
resp.report_generation_results[0].report_output.failed_report_output.error_code #=> String, one of "INSUFFICIENT_PERMISSIONS", "CONFIGURATION_ERROR", "INTERNAL_ERROR"
resp.report_generation_results[0].report_output.failed_report_output.error_message #=> String
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (String)

    Optional. If not provided, lists all reports owned by the account.

  • :report_type (String)

    Filter reports by type.

  • :test_run_id (String)

    The unique identifier of a test run.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



2613
2614
2615
2616
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2613

def list_reports(params = {}, options = {})
  req = build_request(:list_reports, params)
  req.send_request(options)
end

#list_resolved_test_run_target_resources(params = {}) ⇒ Types::ListResolvedTestRunTargetResourcesResponse

Lists the AWS resources that AWS Fault Injection Service (AWS FIS) resolved as targets for a test run.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_resolved_test_run_target_resources({
  test_run_id: "TestRunId", # required
  service_arn: "Arn", # required
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.resolved_target_resources #=> Array
resp.resolved_target_resources[0].resource_type #=> String
resp.resolved_target_resources[0].target_name #=> String
resp.resolved_target_resources[0].target_information #=> Hash
resp.resolved_target_resources[0].target_information["ResolvedTargetInformationKey"] #=> String
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_run_id (required, String)

    The identifier of the test run to list resolved target resources for.

  • :service_arn (required, String)

    The ARN of the service the test run belongs to.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



2662
2663
2664
2665
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2662

def list_resolved_test_run_target_resources(params = {}, options = {})
  req = build_request(:list_resolved_test_run_target_resources, params)
  req.send_request(options)
end

#list_resources(params = {}) ⇒ Types::ListResourcesResponse

List resources.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_resources({
  service_arn: "Arn", # required
  service_function_id: "EntityId",
  aws_region: "AwsRegion",
  resource_types: ["ResourceTypeFilter"],
  billable: false,
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.service_function_id #=> String
resp.service_resources #=> Array
resp.service_resources[0].resource_identifier #=> String
resp.service_resources[0].input_source.identifier #=> String
resp.service_resources[0].input_source.type #=> String, one of "CFN_STACK", "TAGS", "EKS", "TERRAFORM", "DESIGN_FILE", "MONITORING"
resp.service_resources[0].resource.identifier #=> String
resp.service_resources[0].resource.aws_region #=> String
resp.service_resources[0].resource. #=> String
resp.service_resources[0].resource.resource_type #=> String
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :service_function_id (String)

    Filter resources by service function identifier.

  • :aws_region (String)

    Filter resources by AWS Region.

  • :resource_types (Array<String>)

    The CloudFormation resource types to include in the response.

  • :billable (Boolean)

    Specifies whether to filter non-billable resources. When true (the default), the operation returns only billable resources.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



2728
2729
2730
2731
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2728

def list_resources(params = {}, options = {})
  req = build_request(:list_resources, params)
  req.send_request(options)
end

#list_service_events(params = {}) ⇒ Types::ListServiceEventsResponse

Lists events for a service.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_service_events({
  service_arn: "Arn", # required
  event_types: ["SERVICE_CREATED"], # accepts SERVICE_CREATED, SERVICE_DELETED, SERVICE_SYSTEM_ASSOCIATED, SERVICE_SYSTEM_DISASSOCIATED, SERVICE_RESOURCES_ASSOCIATED, SERVICE_RESOURCES_DISASSOCIATED, SERVICE_WORKFLOW_UPDATED, SERVICE_INPUT_SOURCES_UPDATED, SERVICE_POLICY_ASSOCIATED, SERVICE_POLICY_DISASSOCIATED, SERVICE_FUNCTION_CREATED, SERVICE_FUNCTION_UPDATED, SERVICE_FUNCTION_DELETED, SERVICE_FUNCTION_RESOURCES_ADDED, SERVICE_FUNCTION_RESOURCES_REMOVED, SERVICE_ACHIEVABILITY_UPDATED, ASSERTION_CREATED, ASSERTION_UPDATED, ASSERTION_DELETED
  start_time: Time.now,
  end_time: Time.now,
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.events #=> Array
resp.events[0].event_id #=> String
resp.events[0].timestamp #=> Time
resp.events[0].event_type #=> String, one of "SERVICE_CREATED", "SERVICE_DELETED", "SERVICE_SYSTEM_ASSOCIATED", "SERVICE_SYSTEM_DISASSOCIATED", "SERVICE_RESOURCES_ASSOCIATED", "SERVICE_RESOURCES_DISASSOCIATED", "SERVICE_WORKFLOW_UPDATED", "SERVICE_INPUT_SOURCES_UPDATED", "SERVICE_POLICY_ASSOCIATED", "SERVICE_POLICY_DISASSOCIATED", "SERVICE_FUNCTION_CREATED", "SERVICE_FUNCTION_UPDATED", "SERVICE_FUNCTION_DELETED", "SERVICE_FUNCTION_RESOURCES_ADDED", "SERVICE_FUNCTION_RESOURCES_REMOVED", "SERVICE_ACHIEVABILITY_UPDATED", "ASSERTION_CREATED", "ASSERTION_UPDATED", "ASSERTION_DELETED"
resp.events[0].service_arn #=> String
resp.events[0].actor.type #=> String, one of "USER", "SYSTEM"
resp.events[0].actor.principal_id #=> String
resp.events[0].actor. #=> String
resp.events[0].actor.user_name #=> String
resp.events[0].event_details.title #=> String
resp.events[0].event_details.description #=> String
resp.events[0].event_details..service_system_associated.system_name #=> String
resp.events[0].event_details..service_system_associated.system_arn #=> String
resp.events[0].event_details..service_system_disassociated.system_id #=> String
resp.events[0].event_details..service_system_disassociated.system_name #=> String
resp.events[0].event_details..service_system_disassociated.system_arn #=> String
resp.events[0].event_details..service_resources_associated.resource_count #=> Integer
resp.events[0].event_details..service_resources_associated.resource_types #=> Array
resp.events[0].event_details..service_resources_associated.resource_types[0] #=> String
resp.events[0].event_details..service_resources_disassociated.resource_count #=> Integer
resp.events[0].event_details..service_resources_disassociated.resource_types #=> Array
resp.events[0].event_details..service_resources_disassociated.resource_types[0] #=> String
resp.events[0].event_details..service_workflow_updated.service_function_id #=> String
resp.events[0].event_details..service_workflow_updated.service_function_name #=> String
resp.events[0].event_details..service_policy_associated.policy_name #=> String
resp.events[0].event_details..service_policy_associated.policy_arn #=> String
resp.events[0].event_details..service_policy_disassociated.policy_name #=> String
resp.events[0].event_details..service_policy_disassociated.policy_arn #=> String
resp.events[0].event_details..service_function_created.service_function_id #=> String
resp.events[0].event_details..service_function_created.service_function_name #=> String
resp.events[0].event_details..service_function_updated.service_function_id #=> String
resp.events[0].event_details..service_function_updated.service_function_name #=> String
resp.events[0].event_details..service_function_updated.resources_added #=> Array
resp.events[0].event_details..service_function_updated.resources_added[0] #=> String
resp.events[0].event_details..service_function_updated.resources_removed #=> Array
resp.events[0].event_details..service_function_updated.resources_removed[0] #=> String
resp.events[0].event_details..service_function_deleted.service_function_id #=> String
resp.events[0].event_details..service_function_deleted.service_function_name #=> String
resp.events[0].event_details..service_function_resources_added.service_function_id #=> String
resp.events[0].event_details..service_function_resources_added.service_function_name #=> String
resp.events[0].event_details..service_function_resources_added.resources_added #=> Array
resp.events[0].event_details..service_function_resources_added.resources_added[0] #=> String
resp.events[0].event_details..service_function_resources_removed.service_function_id #=> String
resp.events[0].event_details..service_function_resources_removed.service_function_name #=> String
resp.events[0].event_details..service_function_resources_removed.resources_removed #=> Array
resp.events[0].event_details..service_function_resources_removed.resources_removed[0] #=> String
resp.events[0].event_details..service_achievability_updated.assessment_id #=> String
resp.events[0].event_details..service_achievability_updated.availability_slo #=> String
resp.events[0].event_details..service_achievability_updated.multi_az_rto_rpo #=> String
resp.events[0].event_details..service_achievability_updated.multi_region_rto_rpo #=> String
resp.events[0].event_details..assertion_created.assertion_id #=> String
resp.events[0].event_details..assertion_created.assertion_name #=> String
resp.events[0].event_details..assertion_updated.assertion_id #=> String
resp.events[0].event_details..assertion_updated.assertion_name #=> String
resp.events[0].event_details..assertion_deleted.assertion_id #=> String
resp.events[0].event_details..assertion_deleted.assertion_name #=> String
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :event_types (Array<String>)

    Filter events by type.

  • :start_time (Time, DateTime, Date, Integer, String)

    The start time for filtering events.

  • :end_time (Time, DateTime, Date, Integer, String)

    The end time for filtering events.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



2835
2836
2837
2838
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2835

def list_service_events(params = {}, options = {})
  req = build_request(:list_service_events, params)
  req.send_request(options)
end

#list_service_functions(params = {}) ⇒ Types::ListServiceFunctionsResponse

Lists service functions for a service.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_service_functions({
  service_arn: "Arn", # required
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.service_functions #=> Array
resp.service_functions[0].service_arn #=> String
resp.service_functions[0].service_function_id #=> String
resp.service_functions[0].name #=> String
resp.service_functions[0].description #=> String
resp.service_functions[0].criticality #=> String, one of "PRIMARY", "SUPPLEMENTAL"
resp.service_functions[0].resource_count #=> Integer
resp.service_functions[0].source #=> String, one of "AI_GENERATED", "USER"
resp.service_functions[0].created_at #=> Time
resp.service_functions[0].updated_at #=> Time
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



2884
2885
2886
2887
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2884

def list_service_functions(params = {}, options = {})
  req = build_request(:list_service_functions, params)
  req.send_request(options)
end

#list_service_topology_edges(params = {}) ⇒ Types::ListServiceTopologyEdgesResponse

Lists topology edges for a service.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_service_topology_edges({
  service_arn: "Arn", # required
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.service_topology_edge_summaries #=> Array
resp.service_topology_edge_summaries[0].source_resource_identifier #=> String
resp.service_topology_edge_summaries[0].destination_resource_identifier #=> String
resp.service_topology_edge_summaries[0].source_region #=> String
resp.service_topology_edge_summaries[0].destination_region #=> String
resp.service_topology_edge_summaries[0]. #=> String
resp.service_topology_edge_summaries[0]. #=> String
resp.service_topology_edge_summaries[0].properties #=> Array
resp.service_topology_edge_summaries[0].properties[0].topology_type #=> String, one of "CONTAINMENT", "DATA_FLOW", "OBSERVABILITY", "PERMISSIONS"
resp.service_topology_edge_summaries[0].properties[0].label #=> String
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



2933
2934
2935
2936
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 2933

def list_service_topology_edges(params = {}, options = {})
  req = build_request(:list_service_topology_edges, params)
  req.send_request(options)
end

#list_services(params = {}) ⇒ Types::ListServicesResponse

Lists services.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_services({
  system_arn: "Arn",
  user_journey_id: "UserJourneyId",
  ou_id: "OuId",
  account_id: "AccountId",
  assessment_status: "NOT_STARTED", # accepts NOT_STARTED, PENDING, IN_PROGRESS, FAILED, SUCCESS
  policy_arn: "Arn",
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.service_summaries #=> Array
resp.service_summaries[0].service_arn #=> String
resp.service_summaries[0].name #=> String
resp.service_summaries[0].associated_systems #=> Array
resp.service_summaries[0].associated_systems[0].system_arn #=> String
resp.service_summaries[0].associated_systems[0].system_name #=> String
resp.service_summaries[0].associated_systems[0].user_journey_ids #=> Array
resp.service_summaries[0].associated_systems[0].user_journey_ids[0] #=> String
resp.service_summaries[0].regions #=> Array
resp.service_summaries[0].regions[0] #=> String
resp.service_summaries[0].policy_arn #=> String
resp.service_summaries[0].assessment_status #=> String, one of "NOT_STARTED", "PENDING", "IN_PROGRESS", "FAILED", "SUCCESS"
resp.service_summaries[0].open_findings_count #=> Integer
resp.service_summaries[0].resolved_findings_count #=> Integer
resp.service_summaries[0].dependency_discovery.status #=> String, one of "ENABLED", "INITIALIZING", "DISABLED"
resp.service_summaries[0].dependency_discovery.updated_at #=> Time
resp.service_summaries[0].dependency_discovery.eligible_resource_count #=> Integer
resp.service_summaries[0].dependency_discovery.message #=> String
resp.service_summaries[0].achievability.availability_slo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service_summaries[0].achievability.multi_az_rto_rpo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service_summaries[0].achievability.multi_region_rto_rpo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service_summaries[0].achievability.data_recovery_time_between_backups #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service_summaries[0].organization_id #=> String
resp.service_summaries[0].ou_id #=> String
resp.service_summaries[0]. #=> String
resp.service_summaries[0].created_at #=> Time
resp.service_summaries[0].updated_at #=> Time
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :system_arn (String)

    ARN identifier.

  • :user_journey_id (String)

    Filter services by user journey identifier.

  • :ou_id (String)

    Filter services by organizational unit (OU) identifier.

  • :account_id (String)

    Filter services by AWS account ID.

  • :assessment_status (String)

    Filter services by assessment status.

  • :policy_arn (String)

    ARN identifier.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



3019
3020
3021
3022
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3019

def list_services(params = {}, options = {})
  req = build_request(:list_services, params)
  req.send_request(options)
end

#list_system_events(params = {}) ⇒ Types::ListSystemEventsResponse

Lists events for a system.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_system_events({
  system_arn: "Arn", # required
  event_types: ["SYSTEM_CREATED"], # accepts SYSTEM_CREATED, SYSTEM_DELETED, SYSTEM_USER_JOURNEY_CREATED, SYSTEM_USER_JOURNEY_UPDATED, SYSTEM_USER_JOURNEY_DELETED, SYSTEM_SERVICE_ASSOCIATED, SYSTEM_SERVICE_DISASSOCIATED, SYSTEM_POLICY_ASSOCIATED, SYSTEM_POLICY_DISASSOCIATED
  start_time: Time.now,
  end_time: Time.now,
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.events #=> Array
resp.events[0].event_id #=> String
resp.events[0].timestamp #=> Time
resp.events[0].event_type #=> String, one of "SYSTEM_CREATED", "SYSTEM_DELETED", "SYSTEM_USER_JOURNEY_CREATED", "SYSTEM_USER_JOURNEY_UPDATED", "SYSTEM_USER_JOURNEY_DELETED", "SYSTEM_SERVICE_ASSOCIATED", "SYSTEM_SERVICE_DISASSOCIATED", "SYSTEM_POLICY_ASSOCIATED", "SYSTEM_POLICY_DISASSOCIATED"
resp.events[0].system_arn #=> String
resp.events[0].actor.type #=> String, one of "USER", "SYSTEM"
resp.events[0].actor.principal_id #=> String
resp.events[0].actor. #=> String
resp.events[0].actor.user_name #=> String
resp.events[0].event_details.title #=> String
resp.events[0].event_details.description #=> String
resp.events[0].event_details..system_user_journey_created.user_journey_name #=> String
resp.events[0].event_details..system_user_journey_created.associated_services #=> Array
resp.events[0].event_details..system_user_journey_created.associated_services[0].service_id #=> String
resp.events[0].event_details..system_user_journey_created.associated_services[0].service_name #=> String
resp.events[0].event_details..system_user_journey_updated.user_journey_name #=> String
resp.events[0].event_details..system_user_journey_updated.changes.journey_description.old_value #=> String
resp.events[0].event_details..system_user_journey_updated.changes.journey_description.new_value #=> String
resp.events[0].event_details..system_user_journey_updated.changes.associated_services.added #=> Array
resp.events[0].event_details..system_user_journey_updated.changes.associated_services.added[0].service_id #=> String
resp.events[0].event_details..system_user_journey_updated.changes.associated_services.added[0].service_name #=> String
resp.events[0].event_details..system_user_journey_updated.changes.associated_services.removed #=> Array
resp.events[0].event_details..system_user_journey_updated.changes.associated_services.removed[0].service_id #=> String
resp.events[0].event_details..system_user_journey_updated.changes.associated_services.removed[0].service_name #=> String
resp.events[0].event_details..system_user_journey_deleted.user_journey_name #=> String
resp.events[0].event_details..system_user_journey_deleted.associated_services_at_deletion #=> Array
resp.events[0].event_details..system_user_journey_deleted.associated_services_at_deletion[0].service_id #=> String
resp.events[0].event_details..system_user_journey_deleted.associated_services_at_deletion[0].service_name #=> String
resp.events[0].event_details..system_service_associated.service_name #=> String
resp.events[0].event_details..system_service_associated.service_arn #=> String
resp.events[0].event_details..system_service_associated.user_journeys #=> Array
resp.events[0].event_details..system_service_associated.user_journeys[0] #=> String
resp.events[0].event_details..system_service_disassociated.service_name #=> String
resp.events[0].event_details..system_service_disassociated.service_arn #=> String
resp.events[0].event_details..system_service_disassociated.user_journeys_affected #=> Array
resp.events[0].event_details..system_service_disassociated.user_journeys_affected[0] #=> String
resp.events[0].event_details..system_service_disassociated.comment #=> String
resp.events[0].event_details..system_policy_associated.policy_name #=> String
resp.events[0].event_details..system_policy_associated.policy_arn #=> String
resp.events[0].event_details..system_policy_disassociated.policy_name #=> String
resp.events[0].event_details..system_policy_disassociated.policy_arn #=> String
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :system_arn (required, String)

    ARN identifier.

  • :event_types (Array<String>)

    Filter events by type.

  • :start_time (Time, DateTime, Date, Integer, String)

    The start time for filtering events.

  • :end_time (Time, DateTime, Date, Integer, String)

    The end time for filtering events.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



3111
3112
3113
3114
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3111

def list_system_events(params = {}, options = {})
  req = build_request(:list_system_events, params)
  req.send_request(options)
end

#list_systems(params = {}) ⇒ Types::ListSystemsResponse

Lists systems.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_systems({
  ou_id: "OuId",
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.system_summaries #=> Array
resp.system_summaries[0].system_id #=> String
resp.system_summaries[0].name #=> String
resp.system_summaries[0].system_arn #=> String
resp.system_summaries[0].user_journeys_count #=> Integer
resp.system_summaries[0].services_count #=> Integer
resp.system_summaries[0].organization_id #=> String
resp.system_summaries[0].ou_id #=> String
resp.system_summaries[0].created_at #=> Time
resp.system_summaries[0].updated_at #=> Time
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :ou_id (String)

    Filter systems by organizational unit (OU) identifier.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



3160
3161
3162
3163
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3160

def list_systems(params = {}, options = {})
  req = build_request(:list_systems, params)
  req.send_request(options)
end

#list_tags_for_resource(params = {}) ⇒ Types::ListTagsForResourceResponse

Lists the tags for a resource.

Examples:

Request syntax with placeholder values


resp = client.list_tags_for_resource({
  resource_arn: "Arn", # required
})

Response structure


resp.tags #=> Hash
resp.tags["TagKey"] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :resource_arn (required, String)

    ARN identifier.

Returns:

See Also:



3189
3190
3191
3192
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3189

def list_tags_for_resource(params = {}, options = {})
  req = build_request(:list_tags_for_resource, params)
  req.send_request(options)
end

#list_test_run_dependencies(params = {}) ⇒ Types::ListTestRunDependenciesResponse

Lists the dependencies that a test run blocked. Each dependency reflects the discovered classification captured when the run started, so results do not change if a dependency is reclassified after the run.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_test_run_dependencies({
  test_run_id: "TestRunId", # required
  service_arn: "Arn", # required
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.dependencies #=> Array
resp.dependencies[0].dependency_id #=> String
resp.dependencies[0].dependency_name #=> String
resp.dependencies[0].dns_name #=> String
resp.dependencies[0].criticality #=> String, one of "HARD", "SOFT", "UNKNOWN"
resp.dependencies[0].source #=> String, one of "DISCOVERED", "MANUAL"
resp.dependencies[0].location #=> String
resp.dependencies[0].source_regions #=> Array
resp.dependencies[0].source_regions[0] #=> String
resp.dependencies[0].provider #=> String
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_run_id (required, String)

    The identifier of the test run to list dependencies for.

  • :service_arn (required, String)

    The ARN of the service the test run belongs to.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



3245
3246
3247
3248
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3245

def list_test_run_dependencies(params = {}, options = {})
  req = build_request(:list_test_run_dependencies, params)
  req.send_request(options)
end

#list_test_run_events(params = {}) ⇒ Types::ListTestRunEventsResponse

Lists the events in a test run's timeline.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_test_run_events({
  test_run_id: "TestRunId", # required
  service_arn: "Arn", # required
  started_at: Time.now,
  ended_at: Time.now,
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.events #=> Array
resp.events[0].event_id #=> String
resp.events[0].event_type #=> String
resp.events[0].message #=> String
resp.events[0].timestamp #=> Time
resp.events[0].attributes #=> Hash
resp.events[0].attributes["TestRunEventAttributeKey"] #=> String
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_run_id (required, String)

    The identifier of the test run to list events for.

  • :service_arn (required, String)

    The ARN of the service the test run belongs to.

  • :started_at (Time, DateTime, Date, Integer, String)

    Return events at or after this timestamp.

  • :ended_at (Time, DateTime, Date, Integer, String)

    Return events at or before this timestamp.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



3303
3304
3305
3306
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3303

def list_test_run_events(params = {}, options = {})
  req = build_request(:list_test_run_events, params)
  req.send_request(options)
end

#list_test_run_source_events(params = {}) ⇒ Types::ListTestRunSourceEventsResponse

Lists the state-change events observed for a test run monitoring source. Events are returned for one source per call, in chronological order.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_test_run_source_events({
  test_run_id: "TestRunId", # required
  service_arn: "Arn", # required
  source_arn: "TestRunSourceArn", # required
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.test_run_source_events #=> Array
resp.test_run_source_events[0].timestamp #=> Time
resp.test_run_source_events[0].source_arn #=> String
resp.test_run_source_events[0].event_type #=> String, one of "ALARM"
resp.test_run_source_events[0].detail.alarm_state_change.state #=> String, one of "OK", "ALARM", "INSUFFICIENT_DATA"
resp.test_run_source_events[0].detail.alarm_state_change.previous_state #=> String, one of "OK", "ALARM", "INSUFFICIENT_DATA"
resp.test_run_source_events[0].detail.alarm_state_change.reason #=> String
resp.test_run_source_events[0].detail.error.error_code #=> String, one of "ACCESS_DENIED", "INTERNAL_ERROR"
resp.test_run_source_events[0].detail.error.error_message #=> String
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_run_id (required, String)

    The identifier of the test run to list source events for.

  • :service_arn (required, String)

    The ARN of the service the test run belongs to.

  • :source_arn (required, String)

    The ARN of the monitoring source to list events for, such as the ARN of a CloudWatch alarm. If the source was not monitored during the test run, the response is an empty list.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



3363
3364
3365
3366
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3363

def list_test_run_source_events(params = {}, options = {})
  req = build_request(:list_test_run_source_events, params)
  req.send_request(options)
end

#list_test_run_sources(params = {}) ⇒ Types::ListTestRunSourcesResponse

Lists the monitoring source snapshots captured for a test run, optionally filtered by type.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_test_run_sources({
  test_run_id: "TestRunId", # required
  service_arn: "Arn", # required
  type: "SUCCESS_CRITERIA", # accepts SUCCESS_CRITERIA, OBSERVABILITY
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.test_run_sources #=> Array
resp.test_run_sources[0].success_criteria_alarm.alarm_arn #=> String
resp.test_run_sources[0].success_criteria_alarm.alarm_name #=> String
resp.test_run_sources[0].success_criteria_alarm.region #=> String
resp.test_run_sources[0].success_criteria_alarm. #=> String
resp.test_run_sources[0].success_criteria_alarm.outcome #=> String, one of "PASSED", "FAILED", "ERROR"
resp.test_run_sources[0].success_criteria_alarm.outcome_reason #=> String
resp.test_run_sources[0].observability_alarm.alarm_arn #=> String
resp.test_run_sources[0].observability_alarm.alarm_name #=> String
resp.test_run_sources[0].observability_alarm.region #=> String
resp.test_run_sources[0].observability_alarm. #=> String
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_run_id (required, String)

    The identifier of the test run to list sources for.

  • :service_arn (required, String)

    The ARN of the service the test run belongs to.

  • :type (String)

    Filter sources by type.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



3422
3423
3424
3425
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3422

def list_test_run_sources(params = {}, options = {})
  req = build_request(:list_test_run_sources, params)
  req.send_request(options)
end

#list_test_runs(params = {}) ⇒ Types::ListTestRunsResponse

Lists the runs of a test, or all test runs for a service.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_test_runs({
  service_arn: "Arn", # required
  test_id: "TestId",
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.test_runs #=> Array
resp.test_runs[0].test_run_id #=> String
resp.test_runs[0].status #=> String, one of "INITIALIZING", "RUNNING", "STOPPING", "PASSED", "FAILED", "STOPPED", "ERROR"
resp.test_runs[0].started_at #=> Time
resp.test_runs[0].ended_at #=> Time
resp.test_runs[0].test_template_arn #=> String
resp.test_runs[0].service_arn #=> String
resp.test_runs[0].error_message #=> String
resp.test_runs[0]. #=> String, one of "SINGLE_ACCOUNT", "MULTI_ACCOUNT"
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    The ARN of the service to list test runs for.

  • :test_id (String)

    Filter test runs by test identifier.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



3474
3475
3476
3477
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3474

def list_test_runs(params = {}, options = {})
  req = build_request(:list_test_runs, params)
  req.send_request(options)
end

#list_test_sources(params = {}) ⇒ Types::ListTestSourcesResponse

Lists the monitoring sources attached to a test, optionally filtered by type.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_test_sources({
  test_id: "TestId", # required
  service_arn: "Arn", # required
  type: "SUCCESS_CRITERIA", # accepts SUCCESS_CRITERIA, OBSERVABILITY
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.test_sources #=> Array
resp.test_sources[0].success_criteria_alarm.alarm_arn #=> String
resp.test_sources[0].success_criteria_alarm.alarm_name #=> String
resp.test_sources[0].success_criteria_alarm.region #=> String
resp.test_sources[0].success_criteria_alarm. #=> String
resp.test_sources[0].success_criteria_alarm.created_at #=> Time
resp.test_sources[0].observability_alarm.alarm_arn #=> String
resp.test_sources[0].observability_alarm.alarm_name #=> String
resp.test_sources[0].observability_alarm.region #=> String
resp.test_sources[0].observability_alarm. #=> String
resp.test_sources[0].observability_alarm.created_at #=> Time
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_id (required, String)

    The identifier of the test to list sources for.

  • :service_arn (required, String)

    The ARN of the service the test belongs to.

  • :type (String)

    Filter sources by type.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



3533
3534
3535
3536
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3533

def list_test_sources(params = {}, options = {})
  req = build_request(:list_test_sources, params)
  req.send_request(options)
end

#list_test_templates(params = {}) ⇒ Types::ListTestTemplatesResponse

Lists the available resilience test templates. A test template is a pre-configured, AWS recommended test that defines which resilience capability to validate.

Examples:

Response structure


resp.test_templates #=> Array
resp.test_templates[0].test_template_arn #=> String
resp.test_templates[0].name #=> String
resp.test_templates[0].description #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Returns:

See Also:



3557
3558
3559
3560
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3557

def list_test_templates(params = {}, options = {})
  req = build_request(:list_test_templates, params)
  req.send_request(options)
end

#list_tests(params = {}) ⇒ Types::ListTestsResponse

Lists the tests configured for a service.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_tests({
  service_arn: "Arn", # required
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.tests #=> Array
resp.tests[0].test_id #=> String
resp.tests[0].test_template_arn #=> String
resp.tests[0].service_arn #=> String
resp.tests[0].total_test_runs #=> Integer
resp.tests[0].successful_test_runs #=> Integer
resp.tests[0].creation_time #=> Time
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    The ARN of the service to list tests for.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



3603
3604
3605
3606
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3603

def list_tests(params = {}, options = {})
  req = build_request(:list_tests, params)
  req.send_request(options)
end

#list_user_journeys(params = {}) ⇒ Types::ListUserJourneysResponse

Lists user journeys for a system.

The returned response is a pageable response and is Enumerable. For details on usage see PageableResponse.

Examples:

Request syntax with placeholder values


resp = client.list_user_journeys({
  system_arn: "Arn", # required
  max_results: 1,
  next_token: "NextToken",
})

Response structure


resp.user_journey_summaries #=> Array
resp.user_journey_summaries[0].user_journey_id #=> String
resp.user_journey_summaries[0].name #=> String
resp.user_journey_summaries[0].created_at #=> Time
resp.user_journey_summaries[0].updated_at #=> Time
resp.next_token #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :system_arn (required, String)

    ARN identifier.

  • :max_results (Integer)

    Pagination page size.

  • :next_token (String)

    Pagination token.

Returns:

See Also:



3647
3648
3649
3650
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3647

def list_user_journeys(params = {}, options = {})
  req = build_request(:list_user_journeys, params)
  req.send_request(options)
end

#put_test_sources(params = {}) ⇒ Struct

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.

Examples:

Request syntax with placeholder values


resp = client.put_test_sources({
  test_id: "TestId", # required
  service_arn: "Arn", # required
  test_sources: [ # required
    {
      success_criteria_alarm: {
        alarm_arn: "CloudWatchAlarmArn", # required
      },
      observability_alarm: {
        alarm_arn: "CloudWatchAlarmArn", # required
      },
    },
  ],
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_id (required, String)

    The identifier of the test to add sources to.

  • :service_arn (required, String)

    The ARN of the service the test belongs to.

  • :test_sources (required, Array<Types::TestSourceInput>)

    The monitoring sources to add or update.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



3688
3689
3690
3691
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3688

def put_test_sources(params = {}, options = {})
  req = build_request(:put_test_sources, params)
  req.send_request(options)
end

#start_failure_mode_assessment(params = {}) ⇒ Types::StartFailureModeAssessmentResponse

Starts a failure mode assessment.

Examples:

Request syntax with placeholder values


resp = client.start_failure_mode_assessment({
  service_arn: "Arn", # required
  client_token: "ClientToken",
})

Response structure


resp.assessment_id #=> String
resp.service_arn #=> String
resp.assessment_status #=> String, one of "NOT_STARTED", "PENDING", "IN_PROGRESS", "FAILED", "SUCCESS"
resp.started_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :client_token (String)

    Idempotency token.

    A suitable default value is auto-generated. You should normally not need to pass this option.**

Returns:

See Also:



3729
3730
3731
3732
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3729

def start_failure_mode_assessment(params = {}, options = {})
  req = build_request(:start_failure_mode_assessment, params)
  req.send_request(options)
end

#start_test_run(params = {}) ⇒ Types::StartTestRunResponse

Starts a run of a test. Each run scopes to the current resources in the service and produces a pass or fail outcome.

Examples:

Request syntax with placeholder values


resp = client.start_test_run({
  test_id: "TestId", # required
  service_arn: "Arn", # required
})

Response structure


resp.test_run_id #=> String
resp.status #=> String, one of "INITIALIZING", "RUNNING", "STOPPING", "PASSED", "FAILED", "STOPPED", "ERROR"
resp.experiment_arns #=> Array
resp.experiment_arns[0] #=> String

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_id (required, String)

    The identifier of the test to run.

  • :service_arn (required, String)

    The ARN of the service the test belongs to.

Returns:

See Also:



3767
3768
3769
3770
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3767

def start_test_run(params = {}, options = {})
  req = build_request(:start_test_run, params)
  req.send_request(options)
end

#stop_test_run(params = {}) ⇒ Types::StopTestRunResponse

Stops an in-progress test run.

Examples:

Request syntax with placeholder values


resp = client.stop_test_run({
  test_run_id: "TestRunId", # required
  service_arn: "Arn", # required
})

Response structure


resp.test_run_id #=> String
resp.status #=> String, one of "INITIALIZING", "RUNNING", "STOPPING", "PASSED", "FAILED", "STOPPED", "ERROR"

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_run_id (required, String)

    The identifier of the test run to stop.

  • :service_arn (required, String)

    The ARN of the service the test run belongs to.

Returns:

See Also:



3801
3802
3803
3804
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3801

def stop_test_run(params = {}, options = {})
  req = build_request(:stop_test_run, params)
  req.send_request(options)
end

#tag_resource(params = {}) ⇒ Struct

Adds tags to a resource.

Examples:

Request syntax with placeholder values


resp = client.tag_resource({
  resource_arn: "Arn", # required
  tags: { # required
    "TagKey" => "TagValue",
  },
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :resource_arn (required, String)

    ARN identifier.

  • :tags (required, Hash<String,String>)

    Resource tags.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



3829
3830
3831
3832
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3829

def tag_resource(params = {}, options = {})
  req = build_request(:tag_resource, params)
  req.send_request(options)
end

#untag_resource(params = {}) ⇒ Struct

Removes tags from a resource.

Examples:

Request syntax with placeholder values


resp = client.untag_resource({
  resource_arn: "Arn", # required
  tag_keys: ["TagKey"], # required
})

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :resource_arn (required, String)

    ARN identifier.

  • :tag_keys (required, Array<String>)

    The tag keys to remove from the resource.

Returns:

  • (Struct)

    Returns an empty response.

See Also:



3855
3856
3857
3858
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3855

def untag_resource(params = {}, options = {})
  req = build_request(:untag_resource, params)
  req.send_request(options)
end

#update_assertion(params = {}) ⇒ Types::UpdateAssertionResponse

Updates a resilience assertion.

Examples:

Request syntax with placeholder values


resp = client.update_assertion({
  service_arn: "Arn", # required
  assertion_id: "Uuid", # required
  text: "AssertionText",
})

Response structure


resp.assertion.service_arn #=> String
resp.assertion.assertion_id #=> String
resp.assertion.text #=> String
resp.assertion.source #=> String, one of "AI_GENERATED", "USER"
resp.assertion.created_at #=> Time
resp.assertion.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :assertion_id (required, String)

    The unique identifier of the assertion to update.

  • :text (String)

    The updated text content of the assertion.

Returns:

See Also:



3896
3897
3898
3899
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3896

def update_assertion(params = {}, options = {})
  req = build_request(:update_assertion, params)
  req.send_request(options)
end

#update_dependency(params = {}) ⇒ Types::UpdateDependencyResponse

Updates a dependency classification.

Examples:

Request syntax with placeholder values


resp = client.update_dependency({
  service_arn: "Arn", # required
  dependency_id: "Uuid", # required
  criticality: "HARD", # accepts HARD, SOFT, UNKNOWN
  comment: "String",
})

Response structure


resp.dependency_id #=> String
resp.dependency_name #=> String
resp.location #=> String
resp.criticality #=> String, one of "HARD", "SOFT", "UNKNOWN"
resp.comment #=> String
resp.provider #=> String
resp.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :dependency_id (required, String)

    The identifier of the dependency to update.

  • :criticality (String)

    The updated criticality level of the dependency.

  • :comment (String)

    A comment about the dependency.

Returns:

See Also:



3948
3949
3950
3951
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 3948

def update_dependency(params = {}, options = {})
  req = build_request(:update_dependency, params)
  req.send_request(options)
end

#update_failure_mode_finding(params = {}) ⇒ Types::UpdateFailureModeFindingResponse

Updates an existing finding.

Examples:

Request syntax with placeholder values


resp = client.update_failure_mode_finding({
  finding_id: "Uuid", # required
  status: "OPEN", # required, accepts OPEN, RESOLVED, IRRELEVANT
  service_arn: "Arn", # required
  comment: "UpdateFailureModeFindingRequestCommentString",
})

Response structure


resp.finding.finding_id #=> String
resp.finding.name #=> String
resp.finding.description #=> String
resp.finding.failure_category #=> String, one of "SHARED_FATE", "EXCESSIVE_LOAD", "EXCESSIVE_LATENCY", "MISCONFIGURATION_AND_BUGS", "SINGLE_POINT_OF_FAILURE"
resp.finding.status #=> String, one of "OPEN", "RESOLVED", "IRRELEVANT"
resp.finding.reasoning #=> String
resp.finding.comment #=> String
resp.finding.severity #=> String, one of "LOW", "MEDIUM", "HIGH"
resp.finding.service_functions #=> Array
resp.finding.service_functions[0] #=> String
resp.finding.policy_component #=> String, one of "AVAILABILITY_SLO", "MULTI_AZ_DISASTER_RECOVERY", "MULTI_REGION_DISASTER_RECOVERY", "DATA_RECOVERY"
resp.finding.infrastructure_and_code_recommendations #=> Array
resp.finding.infrastructure_and_code_recommendations[0].suggested_changes #=> Array
resp.finding.infrastructure_and_code_recommendations[0].suggested_changes[0] #=> String
resp.finding.observability_recommendations #=> Array
resp.finding.observability_recommendations[0].suggested_changes #=> Array
resp.finding.observability_recommendations[0].suggested_changes[0] #=> String
resp.finding.testing_recommendations #=> Array
resp.finding.testing_recommendations[0].suggested_changes #=> Array
resp.finding.testing_recommendations[0].suggested_changes[0] #=> String
resp.finding.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :finding_id (required, String)

    The identifier of the finding to update.

  • :status (required, String)

    The new status for the finding.

  • :service_arn (required, String)

    ARN identifier.

  • :comment (String)

    A comment about the finding update.

Returns:

See Also:



4008
4009
4010
4011
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 4008

def update_failure_mode_finding(params = {}, options = {})
  req = build_request(:update_failure_mode_finding, params)
  req.send_request(options)
end

#update_policy(params = {}) ⇒ Types::UpdatePolicyResponse

Updates an existing resilience policy.

Examples:

Request syntax with placeholder values


resp = client.update_policy({
  policy_arn: "Arn", # required
  description: "LongDescription",
  availability_slo: {
    target: 1.0,
  },
  multi_az: {
    rto_in_minutes: 1,
    rpo_in_minutes: 1,
    disaster_recovery_approach: "ACTIVE_ACTIVE", # accepts ACTIVE_ACTIVE, HOT_STANDBY, WARM_STANDBY, PILOT_LIGHT, BACKUP_AND_RESTORE
  },
  multi_region: {
    rto_in_minutes: 1,
    rpo_in_minutes: 1,
    disaster_recovery_approach: "ACTIVE_ACTIVE", # accepts ACTIVE_ACTIVE, HOT_STANDBY, WARM_STANDBY, PILOT_LIGHT, BACKUP_AND_RESTORE
  },
  data_recovery: {
    time_between_backups_in_minutes: 1,
  },
})

Response structure


resp.policy.policy_arn #=> String
resp.policy.name #=> String
resp.policy.description #=> String
resp.policy.availability_slo.target #=> Float
resp.policy.multi_az.rto_in_minutes #=> Integer
resp.policy.multi_az.rpo_in_minutes #=> Integer
resp.policy.multi_az.disaster_recovery_approach #=> String, one of "ACTIVE_ACTIVE", "HOT_STANDBY", "WARM_STANDBY", "PILOT_LIGHT", "BACKUP_AND_RESTORE"
resp.policy.multi_region.rto_in_minutes #=> Integer
resp.policy.multi_region.rpo_in_minutes #=> Integer
resp.policy.multi_region.disaster_recovery_approach #=> String, one of "ACTIVE_ACTIVE", "HOT_STANDBY", "WARM_STANDBY", "PILOT_LIGHT", "BACKUP_AND_RESTORE"
resp.policy.data_recovery.time_between_backups_in_minutes #=> Integer
resp.policy.kms_key_id #=> String
resp.policy.tags #=> Hash
resp.policy.tags["TagKey"] #=> String
resp.policy.associated_service_count #=> Integer
resp.policy.created_at #=> Time
resp.policy.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :policy_arn (required, String)

    ARN identifier.

  • :description (String)

    Resource description for services and policies.

  • :availability_slo (Types::AvailabilitySlo)

    The updated availability SLO for the policy.

  • :multi_az (Types::MultiAzTargets)

    The updated multi-AZ disaster recovery targets for the policy.

  • :multi_region (Types::MultiRegionTargets)

    The updated multi-Region disaster recovery targets for the policy.

  • :data_recovery (Types::DataRecoveryTargets)

    The updated data recovery targets for the policy.

Returns:

See Also:



4084
4085
4086
4087
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 4084

def update_policy(params = {}, options = {})
  req = build_request(:update_policy, params)
  req.send_request(options)
end

#update_service(params = {}) ⇒ Types::UpdateServiceResponse

Updates an existing service.

Examples:

Request syntax with placeholder values


resp = client.update_service({
  service_arn: "Arn", # required
  description: "LongDescription",
  associated_systems: [
    {
      system_arn: "Arn", # required
      system_name: "EntityName",
      user_journey_ids: ["UserJourneyId"],
    },
  ],
  policy_arn: "Arn",
  regions: ["AwsRegion"],
  permission_model: {
    invoker_role_name: "IamRoleName", # required
    cross_account_roles: [
      {
        cross_account_role_arn: "IamRoleArn", # required
        external_id: "CrossAccountRoleExternalIdString",
      },
    ],
  },
  dependency_discovery: "ENABLED", # accepts ENABLED, DISABLED
  report_configuration: {
    report_outputs: [ # required
      {
        s3: {
          bucket_path: "S3BucketPath", # required
          bucket_owner: "AwsAccountId", # required
        },
      },
    ],
  },
})

Response structure


resp.service.service_arn #=> String
resp.service.name #=> String
resp.service.description #=> String
resp.service.associated_systems #=> Array
resp.service.associated_systems[0].system_arn #=> String
resp.service.associated_systems[0].system_name #=> String
resp.service.associated_systems[0].user_journey_ids #=> Array
resp.service.associated_systems[0].user_journey_ids[0] #=> String
resp.service.policy_arn #=> String
resp.service.regions #=> Array
resp.service.regions[0] #=> String
resp.service.permission_model.invoker_role_name #=> String
resp.service.permission_model. #=> Array
resp.service.permission_model.[0]. #=> String
resp.service.permission_model.[0].external_id #=> String
resp.service.dependency_discovery.status #=> String, one of "ENABLED", "INITIALIZING", "DISABLED"
resp.service.dependency_discovery.updated_at #=> Time
resp.service.dependency_discovery.eligible_resource_count #=> Integer
resp.service.dependency_discovery.message #=> String
resp.service.effective_policy_values.availability_slo.value #=> Float
resp.service.effective_policy_values.availability_slo.policy_name #=> String
resp.service.effective_policy_values.availability_slo.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_az_rto.value #=> Integer
resp.service.effective_policy_values.multi_az_rto.policy_name #=> String
resp.service.effective_policy_values.multi_az_rto.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_az_rpo.value #=> Integer
resp.service.effective_policy_values.multi_az_rpo.policy_name #=> String
resp.service.effective_policy_values.multi_az_rpo.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_az_dr_approach.value #=> String
resp.service.effective_policy_values.multi_az_dr_approach.policy_name #=> String
resp.service.effective_policy_values.multi_az_dr_approach.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_region_rto.value #=> Integer
resp.service.effective_policy_values.multi_region_rto.policy_name #=> String
resp.service.effective_policy_values.multi_region_rto.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_region_rpo.value #=> Integer
resp.service.effective_policy_values.multi_region_rpo.policy_name #=> String
resp.service.effective_policy_values.multi_region_rpo.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.multi_region_dr_approach.value #=> String
resp.service.effective_policy_values.multi_region_dr_approach.policy_name #=> String
resp.service.effective_policy_values.multi_region_dr_approach.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.effective_policy_values.data_recovery_time_between_backups.value #=> Integer
resp.service.effective_policy_values.data_recovery_time_between_backups.policy_name #=> String
resp.service.effective_policy_values.data_recovery_time_between_backups.source #=> String, one of "SELF", "CROSS_ACCOUNT"
resp.service.achievability.availability_slo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.achievability.multi_az_rto_rpo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.achievability.multi_region_rto_rpo #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.achievability.data_recovery_time_between_backups #=> String, one of "ACHIEVABLE", "NOT_ACHIEVABLE"
resp.service.report_configuration.report_outputs #=> Array
resp.service.report_configuration.report_outputs[0].s3.bucket_path #=> String
resp.service.report_configuration.report_outputs[0].s3.bucket_owner #=> String
resp.service.kms_key_id #=> String
resp.service.tags #=> Hash
resp.service.tags["TagKey"] #=> String
resp.service.estimated_assessment_cost.amount #=> Float
resp.service.estimated_assessment_cost.currency #=> String, one of "USD"
resp.service.resource_discovery.status #=> String, one of "RUNNING", "SUCCEEDED", "FAILED", "COMPLETED_WITH_FAILURES", "NOT_STARTED"
resp.service.resource_discovery.last_run_at #=> Time
resp.service.resource_discovery.error_code #=> String, one of "INVALID_PERMISSIONS", "STACK_NOT_FOUND", "CLUSTER_NOT_FOUND", "STATE_FILE_NOT_FOUND", "ACCESS_DENIED", "UNSUPPORTED_CLUSTER", "INTERNAL_ERROR"
resp.service.resource_discovery.error_message #=> String
resp.service.assessment_status #=> String, one of "NOT_STARTED", "PENDING", "IN_PROGRESS", "FAILED", "SUCCESS"
resp.service.rerun_assessment #=> Boolean
resp.service.open_findings_count #=> Integer
resp.service.resolved_findings_count #=> Integer
resp.service.organization_id #=> String
resp.service.ou_id #=> String
resp.service. #=> String
resp.service.created_at #=> Time
resp.service.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :description (String)

    Resource description for services and policies.

  • :associated_systems (Array<Types::AssociatedSystem>)

    The updated systems to associate with the service.

  • :policy_arn (String)

    ARN identifier.

  • :regions (Array<String>)

    The updated AWS Regions where the service operates.

  • :permission_model (Types::PermissionModel)

    The updated permission model for the service.

  • :dependency_discovery (String)

    Caller-settable values for dependency discovery. INITIALIZING is system-managed.

  • :report_configuration (Types::ServiceReportConfiguration)

    Configuration for automatic report generation on a Service.

Returns:

See Also:



4231
4232
4233
4234
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 4231

def update_service(params = {}, options = {})
  req = build_request(:update_service, params)
  req.send_request(options)
end

#update_service_function(params = {}) ⇒ Types::UpdateServiceFunctionResponse

Updates a service function.

Examples:

Request syntax with placeholder values


resp = client.update_service_function({
  service_arn: "Arn", # required
  service_function_id: "EntityId", # required
  name: "EntityLabel",
  description: "EntityDescription",
  criticality: "PRIMARY", # accepts PRIMARY, SUPPLEMENTAL
})

Response structure


resp.service_function.service_arn #=> String
resp.service_function.service_function_id #=> String
resp.service_function.name #=> String
resp.service_function.description #=> String
resp.service_function.criticality #=> String, one of "PRIMARY", "SUPPLEMENTAL"
resp.service_function.resource_count #=> Integer
resp.service_function.source #=> String, one of "AI_GENERATED", "USER"
resp.service_function.created_at #=> Time
resp.service_function.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :service_arn (required, String)

    ARN identifier.

  • :service_function_id (required, String)

    The identifier of the service function to update.

  • :name (String)

    Entity label (not part of ARN — spaces allowed).

  • :description (String)

    Resource description.

  • :criticality (String)

    The updated criticality level of the service function.

Returns:

See Also:



4283
4284
4285
4286
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 4283

def update_service_function(params = {}, options = {})
  req = build_request(:update_service_function, params)
  req.send_request(options)
end

#update_system(params = {}) ⇒ Types::UpdateSystemResponse

Updates an existing system.

Examples:

Request syntax with placeholder values


resp = client.update_system({
  system_arn: "Arn", # required
  description: "EntityDescription",
  sharing_enabled: false,
})

Response structure


resp.system.system_arn #=> String
resp.system.system_id #=> String
resp.system.name #=> String
resp.system.description #=> String
resp.system.sharing_enabled #=> Boolean
resp.system.tags #=> Hash
resp.system.tags["TagKey"] #=> String
resp.system.kms_key_id #=> String
resp.system.organization_id #=> String
resp.system.ou_id #=> String
resp.system.created_at #=> Time
resp.system.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :system_arn (required, String)

    ARN identifier.

  • :description (String)

    Resource description.

  • :sharing_enabled (Boolean)

    Whether cross-account sharing is enabled for the system.

Returns:

See Also:



4330
4331
4332
4333
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 4330

def update_system(params = {}, options = {})
  req = build_request(:update_system, params)
  req.send_request(options)
end

#update_test(params = {}) ⇒ Types::UpdateTestResponse

Updates the configuration of an existing test.

Examples:

Request syntax with placeholder values


resp = client.update_test({
  test_id: "TestId", # required
  service_arn: "Arn", # required
  logging_configuration: {
    s3_bucket_name: "String",
    cloud_watch_log_group_arn: "Arn",
    log_schema_version: "String",
  },
  stop_conditions: [
    {
      source: "aws:cloudwatch:alarm", # required, accepts aws:cloudwatch:alarm, none
      value: "String", # required
    },
  ],
  role_name: "IamRoleName",
  parameters: {
    "ParameterKey" => ["ParameterValue"],
  },
})

Response structure


resp.test.test_id #=> String
resp.test.test_template_arn #=> String
resp.test.service_arn #=> String
resp.test.name #=> String
resp.test.actions #=> Array
resp.test.actions[0].action_id #=> String
resp.test.actions[0].description #=> String
resp.test.actions[0].resource_type #=> String
resp.test.logging_configuration.s3_bucket_name #=> String
resp.test.logging_configuration.cloud_watch_log_group_arn #=> String
resp.test.logging_configuration.log_schema_version #=> String
resp.test.stop_conditions #=> Array
resp.test.stop_conditions[0].source #=> String, one of "aws:cloudwatch:alarm", "none"
resp.test.stop_conditions[0].value #=> String
resp.test.role_name #=> String
resp.test.parameters #=> Hash
resp.test.parameters["ParameterKey"] #=> Array
resp.test.parameters["ParameterKey"][0] #=> String
resp.test.total_test_runs #=> Integer
resp.test.successful_test_runs #=> Integer
resp.test.creation_time #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :test_id (required, String)

    The identifier of the test to update.

  • :service_arn (required, String)

    The ARN of the service the test belongs to.

  • :logging_configuration (Types::LoggingConfiguration)

    The updated logging configuration for the test.

  • :stop_conditions (Array<Types::StopCondition>)

    The updated stop conditions for the test.

  • :role_name (String)

    The updated IAM execution role name.

  • :parameters (Hash<String,Array>)

    The updated parameter values for the test.

Returns:

See Also:



4409
4410
4411
4412
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 4409

def update_test(params = {}, options = {})
  req = build_request(:update_test, params)
  req.send_request(options)
end

#update_user_journey(params = {}) ⇒ Types::UpdateUserJourneyResponse

Updates an existing user journey.

Examples:

Request syntax with placeholder values


resp = client.update_user_journey({
  system_arn: "Arn", # required
  user_journey_id: "UserJourneyId", # required
  name: "EntityLabel",
  description: "EntityDescription",
  policy_arn: "Arn",
})

Response structure


resp.user_journey.user_journey_id #=> String
resp.user_journey.name #=> String
resp.user_journey.description #=> String
resp.user_journey.policy_arn #=> String
resp.user_journey.created_at #=> Time
resp.user_journey.updated_at #=> Time

Parameters:

  • params (Hash) (defaults to: {})

    ({})

Options Hash (params):

  • :system_arn (required, String)

    ARN identifier.

  • :user_journey_id (required, String)

    The identifier of the user journey to update.

  • :name (String)

    Entity label (not part of ARN — spaces allowed).

  • :description (String)

    Resource description.

  • :policy_arn (String)

    ARN identifier.

Returns:

See Also:



4458
4459
4460
4461
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 4458

def update_user_journey(params = {}, options = {})
  req = build_request(:update_user_journey, params)
  req.send_request(options)
end

#wait_until(waiter_name, params = {}, options = {}) {|w.waiter| ... } ⇒ Boolean

Polls an API operation until a resource enters a desired state.

Basic Usage

A waiter will call an API operation until:

  • It is successful
  • It enters a terminal state
  • It makes the maximum number of attempts

In between attempts, the waiter will sleep.

# polls in a loop, sleeping between attempts
client.wait_until(waiter_name, params)

Configuration

You can configure the maximum number of polling attempts, and the delay (in seconds) between each polling attempt. You can pass configuration as the final arguments hash.

# poll for ~25 seconds
client.wait_until(waiter_name, params, {
  max_attempts: 5,
  delay: 5,
})

Callbacks

You can be notified before each polling attempt and before each delay. If you throw :success or :failure from these callbacks, it will terminate the waiter.

started_at = Time.now
client.wait_until(waiter_name, params, {

  # disable max attempts
  max_attempts: nil,

  # poll for 1 hour, instead of a number of attempts
  before_wait: -> (attempts, response) do
    throw :failure if Time.now - started_at > 3600
  end
})

Handling Errors

When a waiter is unsuccessful, it will raise an error. All of the failure errors extend from Waiters::Errors::WaiterFailed.

begin
  client.wait_until(...)
rescue Aws::Waiters::Errors::WaiterFailed
  # resource did not enter the desired state in time
end

Valid Waiters

The following table lists the valid waiter names, the operations they call, and the default :delay and :max_attempts values.

waiter_name params :delay :max_attempts
failure_mode_assessment_success #list_failure_mode_assessments 30 5
report_succeeded #list_reports 30 5
service_assessment_completed #get_service 30 5
service_resource_discovery_completed #get_service 30 5

Parameters:

  • waiter_name (Symbol)
  • params (Hash) (defaults to: {})

    ({})

  • options (Hash) (defaults to: {})

    ({})

Options Hash (options):

  • :max_attempts (Integer)
  • :delay (Integer)
  • :before_attempt (Proc)
  • :before_wait (Proc)

Yields:

  • (w.waiter)

Returns:

  • (Boolean)

    Returns true if the waiter was successful.

Raises:

  • (Errors::FailureStateError)

    Raised when the waiter terminates because the waiter has entered a state that it will not transition out of, preventing success.

  • (Errors::TooManyAttemptsError)

    Raised when the configured maximum number of attempts have been made, and the waiter is not yet successful.

  • (Errors::UnexpectedError)

    Raised when an error is encounted while polling for a resource that is not expected.

  • (Errors::NoSuchWaiterError)

    Raised when you request to wait for an unknown state.



4576
4577
4578
4579
4580
# File 'gems/aws-sdk-resiliencehubv2/lib/aws-sdk-resiliencehubv2/client.rb', line 4576

def wait_until(waiter_name, params = {}, options = {})
  w = waiter(waiter_name, options)
  yield(w.waiter) if block_given? # deprecated
  w.wait(params)
end