pub struct Client { /* private fields */ }Expand description
Client for AWS Server Migration Service
Client for invoking operations on AWS Server Migration Service. Each operation on AWS Server Migration Service is a method on this
this struct. .send() MUST be invoked on the generated operations to dispatch the request to the service.
§Constructing a Client
A Config is required to construct a client. For most use cases, the aws-config
crate should be used to automatically resolve this config using
aws_config::load_from_env(), since this will resolve an SdkConfig which can be shared
across multiple different AWS SDK clients. This config resolution process can be customized
by calling aws_config::from_env() instead, which returns a ConfigLoader that uses
the builder pattern to customize the default config.
In the simplest case, creating a client looks as follows:
let config = aws_config::load_from_env().await;
let client = aws_sdk_sms::Client::new(&config);Occasionally, SDKs may have additional service-specific values that can be set on the Config that
is absent from SdkConfig, or slightly different settings for a specific client may be desired.
The Builder struct implements From<&SdkConfig>, so setting these specific settings can be
done as follows:
let sdk_config = ::aws_config::load_from_env().await;
let config = aws_sdk_sms::config::Builder::from(&sdk_config)
.some_service_specific_setting("value")
.build();See the aws-config docs and Config for more information on customizing configuration.
Note: Client construction is expensive due to connection thread pool initialization, and should be done once at application start-up.
§Using the Client
A client has a function for every operation that can be performed by the service.
For example, the CreateApp operation has
a Client::create_app, function which returns a builder for that operation.
The fluent builder ultimately has a send() function that returns an async future that
returns a result, as illustrated below:
let result = client.create_app()
.name("example")
.send()
.await;The underlying HTTP requests that get made by this can be modified with the customize_operation
function on the fluent builder. See the customize module for more
information.
Implementations§
Source§impl Client
impl Client
Sourcepub fn create_app(&self) -> CreateAppFluentBuilder
pub fn create_app(&self) -> CreateAppFluentBuilder
Constructs a fluent builder for the CreateApp operation.
- The fluent builder is configurable:
name(impl Into<String>)/set_name(Option<String>):
required: falseThe name of the new application.
description(impl Into<String>)/set_description(Option<String>):
required: falseThe description of the new application
role_name(impl Into<String>)/set_role_name(Option<String>):
required: falseThe name of the service role in the customer’s account to be used by Server Migration Service.
client_token(impl Into<String>)/set_client_token(Option<String>):
required: falseA unique, case-sensitive identifier that you provide to ensure the idempotency of application creation.
server_groups(ServerGroup)/set_server_groups(Option<Vec::<ServerGroup>>):
required: falseThe server groups to include in the application.
tags(Tag)/set_tags(Option<Vec::<Tag>>):
required: falseThe tags to be associated with the application.
- On success, responds with
CreateAppOutputwith field(s):app_summary(Option<AppSummary>):A summary description of the application.
server_groups(Option<Vec::<ServerGroup>>):The server groups included in the application.
tags(Option<Vec::<Tag>>):The tags associated with the application.
- On failure, responds with
SdkError<CreateAppError>
Source§impl Client
impl Client
Sourcepub fn create_replication_job(&self) -> CreateReplicationJobFluentBuilder
pub fn create_replication_job(&self) -> CreateReplicationJobFluentBuilder
Constructs a fluent builder for the CreateReplicationJob operation.
- The fluent builder is configurable:
server_id(impl Into<String>)/set_server_id(Option<String>):
required: trueThe ID of the server.
seed_replication_time(DateTime)/set_seed_replication_time(Option<DateTime>):
required: trueThe seed replication time.
frequency(i32)/set_frequency(Option<i32>):
required: falseThe time between consecutive replication runs, in hours.
run_once(bool)/set_run_once(Option<bool>):
required: falseIndicates whether to run the replication job one time.
license_type(LicenseType)/set_license_type(Option<LicenseType>):
required: falseThe license type to be used for the AMI created by a successful replication run.
role_name(impl Into<String>)/set_role_name(Option<String>):
required: falseThe name of the IAM role to be used by the Server Migration Service.
description(impl Into<String>)/set_description(Option<String>):
required: falseThe description of the replication job.
number_of_recent_amis_to_keep(i32)/set_number_of_recent_amis_to_keep(Option<i32>):
required: falseThe maximum number of SMS-created AMIs to retain. The oldest is deleted after the maximum number is reached and a new AMI is created.
encrypted(bool)/set_encrypted(Option<bool>):
required: falseIndicates whether the replication job produces encrypted AMIs.
kms_key_id(impl Into<String>)/set_kms_key_id(Option<String>):
required: falseThe ID of the KMS key for replication jobs that produce encrypted AMIs. This value can be any of the following:
-
KMS key ID
-
KMS key alias
-
ARN referring to the KMS key ID
-
ARN referring to the KMS key alias
If encrypted is true but a KMS key ID is not specified, the customer’s default KMS key for Amazon EBS is used.
-
- On success, responds with
CreateReplicationJobOutputwith field(s):replication_job_id(Option<String>):The unique identifier of the replication job.
- On failure, responds with
SdkError<CreateReplicationJobError>
Source§impl Client
impl Client
Sourcepub fn delete_app(&self) -> DeleteAppFluentBuilder
pub fn delete_app(&self) -> DeleteAppFluentBuilder
Constructs a fluent builder for the DeleteApp operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
force_stop_app_replication(bool)/set_force_stop_app_replication(Option<bool>):
required: falseIndicates whether to stop all replication jobs corresponding to the servers in the application while deleting the application.
force_terminate_app(bool)/set_force_terminate_app(Option<bool>):
required: falseIndicates whether to terminate the stack corresponding to the application while deleting the application.
- On success, responds with
DeleteAppOutput - On failure, responds with
SdkError<DeleteAppError>
Source§impl Client
impl Client
Sourcepub fn delete_app_launch_configuration(
&self,
) -> DeleteAppLaunchConfigurationFluentBuilder
pub fn delete_app_launch_configuration( &self, ) -> DeleteAppLaunchConfigurationFluentBuilder
Constructs a fluent builder for the DeleteAppLaunchConfiguration operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
- On success, responds with
DeleteAppLaunchConfigurationOutput - On failure, responds with
SdkError<DeleteAppLaunchConfigurationError>
Source§impl Client
impl Client
Sourcepub fn delete_app_replication_configuration(
&self,
) -> DeleteAppReplicationConfigurationFluentBuilder
pub fn delete_app_replication_configuration( &self, ) -> DeleteAppReplicationConfigurationFluentBuilder
Constructs a fluent builder for the DeleteAppReplicationConfiguration operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
- On success, responds with
DeleteAppReplicationConfigurationOutput - On failure, responds with
SdkError<DeleteAppReplicationConfigurationError>
Source§impl Client
impl Client
Sourcepub fn delete_app_validation_configuration(
&self,
) -> DeleteAppValidationConfigurationFluentBuilder
pub fn delete_app_validation_configuration( &self, ) -> DeleteAppValidationConfigurationFluentBuilder
Constructs a fluent builder for the DeleteAppValidationConfiguration operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: trueThe ID of the application.
- On success, responds with
DeleteAppValidationConfigurationOutput - On failure, responds with
SdkError<DeleteAppValidationConfigurationError>
Source§impl Client
impl Client
Sourcepub fn delete_replication_job(&self) -> DeleteReplicationJobFluentBuilder
pub fn delete_replication_job(&self) -> DeleteReplicationJobFluentBuilder
Constructs a fluent builder for the DeleteReplicationJob operation.
- The fluent builder is configurable:
replication_job_id(impl Into<String>)/set_replication_job_id(Option<String>):
required: trueThe ID of the replication job.
- On success, responds with
DeleteReplicationJobOutput - On failure, responds with
SdkError<DeleteReplicationJobError>
Source§impl Client
impl Client
Sourcepub fn delete_server_catalog(&self) -> DeleteServerCatalogFluentBuilder
pub fn delete_server_catalog(&self) -> DeleteServerCatalogFluentBuilder
Constructs a fluent builder for the DeleteServerCatalog operation.
- The fluent builder takes no input, just
sendit. - On success, responds with
DeleteServerCatalogOutput - On failure, responds with
SdkError<DeleteServerCatalogError>
Source§impl Client
impl Client
Sourcepub fn disassociate_connector(&self) -> DisassociateConnectorFluentBuilder
pub fn disassociate_connector(&self) -> DisassociateConnectorFluentBuilder
Constructs a fluent builder for the DisassociateConnector operation.
- The fluent builder is configurable:
connector_id(impl Into<String>)/set_connector_id(Option<String>):
required: trueThe ID of the connector.
- On success, responds with
DisassociateConnectorOutput - On failure, responds with
SdkError<DisassociateConnectorError>
Source§impl Client
impl Client
Sourcepub fn generate_change_set(&self) -> GenerateChangeSetFluentBuilder
pub fn generate_change_set(&self) -> GenerateChangeSetFluentBuilder
Constructs a fluent builder for the GenerateChangeSet operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application associated with the change set.
changeset_format(OutputFormat)/set_changeset_format(Option<OutputFormat>):
required: falseThe format for the change set.
- On success, responds with
GenerateChangeSetOutputwith field(s):s3_location(Option<S3Location>):The location of the Amazon S3 object.
- On failure, responds with
SdkError<GenerateChangeSetError>
Source§impl Client
impl Client
Sourcepub fn generate_template(&self) -> GenerateTemplateFluentBuilder
pub fn generate_template(&self) -> GenerateTemplateFluentBuilder
Constructs a fluent builder for the GenerateTemplate operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application associated with the CloudFormation template.
template_format(OutputFormat)/set_template_format(Option<OutputFormat>):
required: falseThe format for generating the CloudFormation template.
- On success, responds with
GenerateTemplateOutputwith field(s):s3_location(Option<S3Location>):The location of the Amazon S3 object.
- On failure, responds with
SdkError<GenerateTemplateError>
Source§impl Client
impl Client
Sourcepub fn get_app(&self) -> GetAppFluentBuilder
pub fn get_app(&self) -> GetAppFluentBuilder
Constructs a fluent builder for the GetApp operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
- On success, responds with
GetAppOutputwith field(s):app_summary(Option<AppSummary>):Information about the application.
server_groups(Option<Vec::<ServerGroup>>):The server groups that belong to the application.
tags(Option<Vec::<Tag>>):The tags associated with the application.
- On failure, responds with
SdkError<GetAppError>
Source§impl Client
impl Client
Sourcepub fn get_app_launch_configuration(
&self,
) -> GetAppLaunchConfigurationFluentBuilder
pub fn get_app_launch_configuration( &self, ) -> GetAppLaunchConfigurationFluentBuilder
Constructs a fluent builder for the GetAppLaunchConfiguration operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
- On success, responds with
GetAppLaunchConfigurationOutputwith field(s):app_id(Option<String>):The ID of the application.
role_name(Option<String>):The name of the service role in the customer’s account that CloudFormation uses to launch the application.
auto_launch(Option<bool>):Indicates whether the application is configured to launch automatically after replication is complete.
server_group_launch_configurations(Option<Vec::<ServerGroupLaunchConfiguration>>):The launch configurations for server groups in this application.
- On failure, responds with
SdkError<GetAppLaunchConfigurationError>
Source§impl Client
impl Client
Sourcepub fn get_app_replication_configuration(
&self,
) -> GetAppReplicationConfigurationFluentBuilder
pub fn get_app_replication_configuration( &self, ) -> GetAppReplicationConfigurationFluentBuilder
Constructs a fluent builder for the GetAppReplicationConfiguration operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
- On success, responds with
GetAppReplicationConfigurationOutputwith field(s):server_group_replication_configurations(Option<Vec::<ServerGroupReplicationConfiguration>>):The replication configurations associated with server groups in this application.
- On failure, responds with
SdkError<GetAppReplicationConfigurationError>
Source§impl Client
impl Client
Sourcepub fn get_app_validation_configuration(
&self,
) -> GetAppValidationConfigurationFluentBuilder
pub fn get_app_validation_configuration( &self, ) -> GetAppValidationConfigurationFluentBuilder
Constructs a fluent builder for the GetAppValidationConfiguration operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: trueThe ID of the application.
- On success, responds with
GetAppValidationConfigurationOutputwith field(s):app_validation_configurations(Option<Vec::<AppValidationConfiguration>>):The configuration for application validation.
server_group_validation_configurations(Option<Vec::<ServerGroupValidationConfiguration>>):The configuration for instance validation.
- On failure, responds with
SdkError<GetAppValidationConfigurationError>
Source§impl Client
impl Client
Sourcepub fn get_app_validation_output(&self) -> GetAppValidationOutputFluentBuilder
pub fn get_app_validation_output(&self) -> GetAppValidationOutputFluentBuilder
Constructs a fluent builder for the GetAppValidationOutput operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: trueThe ID of the application.
- On success, responds with
GetAppValidationOutputOutputwith field(s):validation_output_list(Option<Vec::<ValidationOutput>>):The validation output.
- On failure, responds with
SdkError<GetAppValidationOutputError>
Source§impl Client
impl Client
Sourcepub fn get_connectors(&self) -> GetConnectorsFluentBuilder
pub fn get_connectors(&self) -> GetConnectorsFluentBuilder
Constructs a fluent builder for the GetConnectors operation.
This operation supports pagination; See into_paginator().
- The fluent builder is configurable:
next_token(impl Into<String>)/set_next_token(Option<String>):
required: falseThe token for the next set of results.
max_results(i32)/set_max_results(Option<i32>):
required: falseThe maximum number of results to return in a single call. The default value is 50. To retrieve the remaining results, make another call with the returned
NextTokenvalue.
- On success, responds with
GetConnectorsOutputwith field(s):connector_list(Option<Vec::<Connector>>):Information about the registered connectors.
next_token(Option<String>):The token required to retrieve the next set of results. This value is null when there are no more results to return.
- On failure, responds with
SdkError<GetConnectorsError>
Source§impl Client
impl Client
Sourcepub fn get_replication_jobs(&self) -> GetReplicationJobsFluentBuilder
pub fn get_replication_jobs(&self) -> GetReplicationJobsFluentBuilder
Constructs a fluent builder for the GetReplicationJobs operation.
This operation supports pagination; See into_paginator().
- The fluent builder is configurable:
replication_job_id(impl Into<String>)/set_replication_job_id(Option<String>):
required: falseThe ID of the replication job.
next_token(impl Into<String>)/set_next_token(Option<String>):
required: falseThe token for the next set of results.
max_results(i32)/set_max_results(Option<i32>):
required: falseThe maximum number of results to return in a single call. The default value is 50. To retrieve the remaining results, make another call with the returned
NextTokenvalue.
- On success, responds with
GetReplicationJobsOutputwith field(s):replication_job_list(Option<Vec::<ReplicationJob>>):Information about the replication jobs.
next_token(Option<String>):The token required to retrieve the next set of results. This value is null when there are no more results to return.
- On failure, responds with
SdkError<GetReplicationJobsError>
Source§impl Client
impl Client
Sourcepub fn get_replication_runs(&self) -> GetReplicationRunsFluentBuilder
pub fn get_replication_runs(&self) -> GetReplicationRunsFluentBuilder
Constructs a fluent builder for the GetReplicationRuns operation.
This operation supports pagination; See into_paginator().
- The fluent builder is configurable:
replication_job_id(impl Into<String>)/set_replication_job_id(Option<String>):
required: trueThe ID of the replication job.
next_token(impl Into<String>)/set_next_token(Option<String>):
required: falseThe token for the next set of results.
max_results(i32)/set_max_results(Option<i32>):
required: falseThe maximum number of results to return in a single call. The default value is 50. To retrieve the remaining results, make another call with the returned
NextTokenvalue.
- On success, responds with
GetReplicationRunsOutputwith field(s):replication_job(Option<ReplicationJob>):Information about the replication job.
replication_run_list(Option<Vec::<ReplicationRun>>):Information about the replication runs.
next_token(Option<String>):The token required to retrieve the next set of results. This value is null when there are no more results to return.
- On failure, responds with
SdkError<GetReplicationRunsError>
Source§impl Client
impl Client
Sourcepub fn get_servers(&self) -> GetServersFluentBuilder
pub fn get_servers(&self) -> GetServersFluentBuilder
Constructs a fluent builder for the GetServers operation.
This operation supports pagination; See into_paginator().
- The fluent builder is configurable:
next_token(impl Into<String>)/set_next_token(Option<String>):
required: falseThe token for the next set of results.
max_results(i32)/set_max_results(Option<i32>):
required: falseThe maximum number of results to return in a single call. The default value is 50. To retrieve the remaining results, make another call with the returned
NextTokenvalue.vm_server_address_list(VmServerAddress)/set_vm_server_address_list(Option<Vec::<VmServerAddress>>):
required: falseThe server addresses.
- On success, responds with
GetServersOutputwith field(s):last_modified_on(Option<DateTime>):The time when the server was last modified.
server_catalog_status(Option<ServerCatalogStatus>):The status of the server catalog.
server_list(Option<Vec::<Server>>):Information about the servers.
next_token(Option<String>):The token required to retrieve the next set of results. This value is null when there are no more results to return.
- On failure, responds with
SdkError<GetServersError>
Source§impl Client
impl Client
Sourcepub fn import_app_catalog(&self) -> ImportAppCatalogFluentBuilder
pub fn import_app_catalog(&self) -> ImportAppCatalogFluentBuilder
Constructs a fluent builder for the ImportAppCatalog operation.
- The fluent builder is configurable:
role_name(impl Into<String>)/set_role_name(Option<String>):
required: falseThe name of the service role. If you omit this parameter, we create a service-linked role for Migration Hub in your account. Otherwise, the role that you provide must have the policy and trust policy described in the Migration Hub User Guide.
- On success, responds with
ImportAppCatalogOutput - On failure, responds with
SdkError<ImportAppCatalogError>
Source§impl Client
impl Client
Sourcepub fn import_server_catalog(&self) -> ImportServerCatalogFluentBuilder
pub fn import_server_catalog(&self) -> ImportServerCatalogFluentBuilder
Constructs a fluent builder for the ImportServerCatalog operation.
- The fluent builder takes no input, just
sendit. - On success, responds with
ImportServerCatalogOutput - On failure, responds with
SdkError<ImportServerCatalogError>
Source§impl Client
impl Client
Sourcepub fn launch_app(&self) -> LaunchAppFluentBuilder
pub fn launch_app(&self) -> LaunchAppFluentBuilder
Constructs a fluent builder for the LaunchApp operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
- On success, responds with
LaunchAppOutput - On failure, responds with
SdkError<LaunchAppError>
Source§impl Client
impl Client
Sourcepub fn list_apps(&self) -> ListAppsFluentBuilder
pub fn list_apps(&self) -> ListAppsFluentBuilder
Constructs a fluent builder for the ListApps operation.
- The fluent builder is configurable:
app_ids(impl Into<String>)/set_app_ids(Option<Vec::<String>>):
required: falseThe unique application IDs.
next_token(impl Into<String>)/set_next_token(Option<String>):
required: falseThe token for the next set of results.
max_results(i32)/set_max_results(Option<i32>):
required: falseThe maximum number of results to return in a single call. The default value is 100. To retrieve the remaining results, make another call with the returned
NextTokenvalue.
- On success, responds with
ListAppsOutputwith field(s):apps(Option<Vec::<AppSummary>>):The application summaries.
next_token(Option<String>):The token required to retrieve the next set of results. This value is null when there are no more results to return.
- On failure, responds with
SdkError<ListAppsError>
Source§impl Client
impl Client
Sourcepub fn notify_app_validation_output(
&self,
) -> NotifyAppValidationOutputFluentBuilder
pub fn notify_app_validation_output( &self, ) -> NotifyAppValidationOutputFluentBuilder
Constructs a fluent builder for the NotifyAppValidationOutput operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: trueThe ID of the application.
notification_context(NotificationContext)/set_notification_context(Option<NotificationContext>):
required: falseThe notification information.
- On success, responds with
NotifyAppValidationOutputOutput - On failure, responds with
SdkError<NotifyAppValidationOutputError>
Source§impl Client
impl Client
Sourcepub fn put_app_launch_configuration(
&self,
) -> PutAppLaunchConfigurationFluentBuilder
pub fn put_app_launch_configuration( &self, ) -> PutAppLaunchConfigurationFluentBuilder
Constructs a fluent builder for the PutAppLaunchConfiguration operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
role_name(impl Into<String>)/set_role_name(Option<String>):
required: falseThe name of service role in the customer’s account that CloudFormation uses to launch the application.
auto_launch(bool)/set_auto_launch(Option<bool>):
required: falseIndicates whether the application is configured to launch automatically after replication is complete.
server_group_launch_configurations(ServerGroupLaunchConfiguration)/set_server_group_launch_configurations(Option<Vec::<ServerGroupLaunchConfiguration>>):
required: falseInformation about the launch configurations for server groups in the application.
- On success, responds with
PutAppLaunchConfigurationOutput - On failure, responds with
SdkError<PutAppLaunchConfigurationError>
Source§impl Client
impl Client
Sourcepub fn put_app_replication_configuration(
&self,
) -> PutAppReplicationConfigurationFluentBuilder
pub fn put_app_replication_configuration( &self, ) -> PutAppReplicationConfigurationFluentBuilder
Constructs a fluent builder for the PutAppReplicationConfiguration operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
server_group_replication_configurations(ServerGroupReplicationConfiguration)/set_server_group_replication_configurations(Option<Vec::<ServerGroupReplicationConfiguration>>):
required: falseInformation about the replication configurations for server groups in the application.
- On success, responds with
PutAppReplicationConfigurationOutput - On failure, responds with
SdkError<PutAppReplicationConfigurationError>
Source§impl Client
impl Client
Sourcepub fn put_app_validation_configuration(
&self,
) -> PutAppValidationConfigurationFluentBuilder
pub fn put_app_validation_configuration( &self, ) -> PutAppValidationConfigurationFluentBuilder
Constructs a fluent builder for the PutAppValidationConfiguration operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: trueThe ID of the application.
app_validation_configurations(AppValidationConfiguration)/set_app_validation_configurations(Option<Vec::<AppValidationConfiguration>>):
required: falseThe configuration for application validation.
server_group_validation_configurations(ServerGroupValidationConfiguration)/set_server_group_validation_configurations(Option<Vec::<ServerGroupValidationConfiguration>>):
required: falseThe configuration for instance validation.
- On success, responds with
PutAppValidationConfigurationOutput - On failure, responds with
SdkError<PutAppValidationConfigurationError>
Source§impl Client
impl Client
Sourcepub fn start_app_replication(&self) -> StartAppReplicationFluentBuilder
pub fn start_app_replication(&self) -> StartAppReplicationFluentBuilder
Constructs a fluent builder for the StartAppReplication operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
- On success, responds with
StartAppReplicationOutput - On failure, responds with
SdkError<StartAppReplicationError>
Source§impl Client
impl Client
Sourcepub fn start_on_demand_app_replication(
&self,
) -> StartOnDemandAppReplicationFluentBuilder
pub fn start_on_demand_app_replication( &self, ) -> StartOnDemandAppReplicationFluentBuilder
Constructs a fluent builder for the StartOnDemandAppReplication operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: trueThe ID of the application.
description(impl Into<String>)/set_description(Option<String>):
required: falseThe description of the replication run.
- On success, responds with
StartOnDemandAppReplicationOutput - On failure, responds with
SdkError<StartOnDemandAppReplicationError>
Source§impl Client
impl Client
Sourcepub fn start_on_demand_replication_run(
&self,
) -> StartOnDemandReplicationRunFluentBuilder
pub fn start_on_demand_replication_run( &self, ) -> StartOnDemandReplicationRunFluentBuilder
Constructs a fluent builder for the StartOnDemandReplicationRun operation.
- The fluent builder is configurable:
replication_job_id(impl Into<String>)/set_replication_job_id(Option<String>):
required: trueThe ID of the replication job.
description(impl Into<String>)/set_description(Option<String>):
required: falseThe description of the replication run.
- On success, responds with
StartOnDemandReplicationRunOutputwith field(s):replication_run_id(Option<String>):The ID of the replication run.
- On failure, responds with
SdkError<StartOnDemandReplicationRunError>
Source§impl Client
impl Client
Sourcepub fn stop_app_replication(&self) -> StopAppReplicationFluentBuilder
pub fn stop_app_replication(&self) -> StopAppReplicationFluentBuilder
Constructs a fluent builder for the StopAppReplication operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
- On success, responds with
StopAppReplicationOutput - On failure, responds with
SdkError<StopAppReplicationError>
Source§impl Client
impl Client
Sourcepub fn terminate_app(&self) -> TerminateAppFluentBuilder
pub fn terminate_app(&self) -> TerminateAppFluentBuilder
Constructs a fluent builder for the TerminateApp operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
- On success, responds with
TerminateAppOutput - On failure, responds with
SdkError<TerminateAppError>
Source§impl Client
impl Client
Sourcepub fn update_app(&self) -> UpdateAppFluentBuilder
pub fn update_app(&self) -> UpdateAppFluentBuilder
Constructs a fluent builder for the UpdateApp operation.
- The fluent builder is configurable:
app_id(impl Into<String>)/set_app_id(Option<String>):
required: falseThe ID of the application.
name(impl Into<String>)/set_name(Option<String>):
required: falseThe new name of the application.
description(impl Into<String>)/set_description(Option<String>):
required: falseThe new description of the application.
role_name(impl Into<String>)/set_role_name(Option<String>):
required: falseThe name of the service role in the customer’s account used by Server Migration Service.
server_groups(ServerGroup)/set_server_groups(Option<Vec::<ServerGroup>>):
required: falseThe server groups in the application to update.
tags(Tag)/set_tags(Option<Vec::<Tag>>):
required: falseThe tags to associate with the application.
- On success, responds with
UpdateAppOutputwith field(s):app_summary(Option<AppSummary>):A summary description of the application.
server_groups(Option<Vec::<ServerGroup>>):The updated server groups in the application.
tags(Option<Vec::<Tag>>):The tags associated with the application.
- On failure, responds with
SdkError<UpdateAppError>
Source§impl Client
impl Client
Sourcepub fn update_replication_job(&self) -> UpdateReplicationJobFluentBuilder
pub fn update_replication_job(&self) -> UpdateReplicationJobFluentBuilder
Constructs a fluent builder for the UpdateReplicationJob operation.
- The fluent builder is configurable:
replication_job_id(impl Into<String>)/set_replication_job_id(Option<String>):
required: trueThe ID of the replication job.
frequency(i32)/set_frequency(Option<i32>):
required: falseThe time between consecutive replication runs, in hours.
next_replication_run_start_time(DateTime)/set_next_replication_run_start_time(Option<DateTime>):
required: falseThe start time of the next replication run.
license_type(LicenseType)/set_license_type(Option<LicenseType>):
required: falseThe license type to be used for the AMI created by a successful replication run.
role_name(impl Into<String>)/set_role_name(Option<String>):
required: falseThe name of the IAM role to be used by Server Migration Service.
description(impl Into<String>)/set_description(Option<String>):
required: falseThe description of the replication job.
number_of_recent_amis_to_keep(i32)/set_number_of_recent_amis_to_keep(Option<i32>):
required: falseThe maximum number of SMS-created AMIs to retain. The oldest is deleted after the maximum number is reached and a new AMI is created.
encrypted(bool)/set_encrypted(Option<bool>):
required: falseWhen true, the replication job produces encrypted AMIs. For more information,
KmsKeyId.kms_key_id(impl Into<String>)/set_kms_key_id(Option<String>):
required: falseThe ID of the KMS key for replication jobs that produce encrypted AMIs. This value can be any of the following:
-
KMS key ID
-
KMS key alias
-
ARN referring to the KMS key ID
-
ARN referring to the KMS key alias
If encrypted is enabled but a KMS key ID is not specified, the customer’s default KMS key for Amazon EBS is used.
-
- On success, responds with
UpdateReplicationJobOutput - On failure, responds with
SdkError<UpdateReplicationJobError>
Source§impl Client
impl Client
Sourcepub fn from_conf(conf: Config) -> Self
pub fn from_conf(conf: Config) -> Self
Creates a new client from the service Config.
§Panics
This method will panic in the following cases:
- Retries or timeouts are enabled without a
sleep_implconfigured. - Identity caching is enabled without a
sleep_implandtime_sourceconfigured. - No
behavior_versionis provided.
The panic message for each of these will have instructions on how to resolve them.
Source§impl Client
impl Client
Sourcepub fn new(sdk_config: &SdkConfig) -> Self
pub fn new(sdk_config: &SdkConfig) -> Self
Creates a new client from an SDK Config.
§Panics
- This method will panic if the
sdk_configis missing an async sleep implementation. If you experience this panic, set thesleep_implon the Config passed into this function to fix it. - This method will panic if the
sdk_configis missing an HTTP connector. If you experience this panic, set thehttp_connectoron the Config passed into this function to fix it. - This method will panic if no
BehaviorVersionis provided. If you experience this panic, setbehavior_versionon the Config or enable thebehavior-version-latestCargo feature.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Client
impl !RefUnwindSafe for Client
impl Send for Client
impl Sync for Client
impl Unpin for Client
impl !UnwindSafe for Client
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Paint for Twhere
T: ?Sized,
impl<T> Paint for Twhere
T: ?Sized,
Source§fn fg(&self, value: Color) -> Painted<&T>
fn fg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self with the foreground set to
value.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like red() and
green(), which have the same functionality but are
pithier.
§Example
Set foreground color to white using fg():
use yansi::{Paint, Color};
painted.fg(Color::White);Set foreground color to white using white().
use yansi::Paint;
painted.white();Source§fn bright_black(&self) -> Painted<&T>
fn bright_black(&self) -> Painted<&T>
Source§fn bright_red(&self) -> Painted<&T>
fn bright_red(&self) -> Painted<&T>
Source§fn bright_green(&self) -> Painted<&T>
fn bright_green(&self) -> Painted<&T>
Source§fn bright_yellow(&self) -> Painted<&T>
fn bright_yellow(&self) -> Painted<&T>
Source§fn bright_blue(&self) -> Painted<&T>
fn bright_blue(&self) -> Painted<&T>
Source§fn bright_magenta(&self) -> Painted<&T>
fn bright_magenta(&self) -> Painted<&T>
Source§fn bright_cyan(&self) -> Painted<&T>
fn bright_cyan(&self) -> Painted<&T>
Source§fn bright_white(&self) -> Painted<&T>
fn bright_white(&self) -> Painted<&T>
Source§fn bg(&self, value: Color) -> Painted<&T>
fn bg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self with the background set to
value.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like on_red() and
on_green(), which have the same functionality but
are pithier.
§Example
Set background color to red using fg():
use yansi::{Paint, Color};
painted.bg(Color::Red);Set background color to red using on_red().
use yansi::Paint;
painted.on_red();Source§fn on_primary(&self) -> Painted<&T>
fn on_primary(&self) -> Painted<&T>
Source§fn on_magenta(&self) -> Painted<&T>
fn on_magenta(&self) -> Painted<&T>
Source§fn on_bright_black(&self) -> Painted<&T>
fn on_bright_black(&self) -> Painted<&T>
Source§fn on_bright_red(&self) -> Painted<&T>
fn on_bright_red(&self) -> Painted<&T>
Source§fn on_bright_green(&self) -> Painted<&T>
fn on_bright_green(&self) -> Painted<&T>
Source§fn on_bright_yellow(&self) -> Painted<&T>
fn on_bright_yellow(&self) -> Painted<&T>
Source§fn on_bright_blue(&self) -> Painted<&T>
fn on_bright_blue(&self) -> Painted<&T>
Source§fn on_bright_magenta(&self) -> Painted<&T>
fn on_bright_magenta(&self) -> Painted<&T>
Source§fn on_bright_cyan(&self) -> Painted<&T>
fn on_bright_cyan(&self) -> Painted<&T>
Source§fn on_bright_white(&self) -> Painted<&T>
fn on_bright_white(&self) -> Painted<&T>
Source§fn attr(&self, value: Attribute) -> Painted<&T>
fn attr(&self, value: Attribute) -> Painted<&T>
Enables the styling Attribute value.
This method should be used rarely. Instead, prefer to use
attribute-specific builder methods like bold() and
underline(), which have the same functionality
but are pithier.
§Example
Make text bold using attr():
use yansi::{Paint, Attribute};
painted.attr(Attribute::Bold);Make text bold using using bold().
use yansi::Paint;
painted.bold();Source§fn rapid_blink(&self) -> Painted<&T>
fn rapid_blink(&self) -> Painted<&T>
Source§fn quirk(&self, value: Quirk) -> Painted<&T>
fn quirk(&self, value: Quirk) -> Painted<&T>
Enables the yansi Quirk value.
This method should be used rarely. Instead, prefer to use quirk-specific
builder methods like mask() and
wrap(), which have the same functionality but are
pithier.
§Example
Enable wrapping using .quirk():
use yansi::{Paint, Quirk};
painted.quirk(Quirk::Wrap);Enable wrapping using wrap().
use yansi::Paint;
painted.wrap();Source§fn clear(&self) -> Painted<&T>
👎Deprecated since 1.0.1: renamed to resetting() due to conflicts with Vec::clear().
The clear() method will be removed in a future release.
fn clear(&self) -> Painted<&T>
resetting() due to conflicts with Vec::clear().
The clear() method will be removed in a future release.Source§fn whenever(&self, value: Condition) -> Painted<&T>
fn whenever(&self, value: Condition) -> Painted<&T>
Conditionally enable styling based on whether the Condition value
applies. Replaces any previous condition.
See the crate level docs for more details.
§Example
Enable styling painted only when both stdout and stderr are TTYs:
use yansi::{Paint, Condition};
painted.red().on_yellow().whenever(Condition::STDOUTERR_ARE_TTY);