pub struct Client { /* private fields */ }Expand description
Client for AWS Migration Hub
Client for invoking operations on AWS Migration Hub. Each operation on AWS Migration Hub 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_migrationhub::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_migrationhub::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 AssociateCreatedArtifact operation has
a Client::associate_created_artifact, 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.associate_created_artifact()
.progress_update_stream("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 associate_created_artifact(
&self,
) -> AssociateCreatedArtifactFluentBuilder
pub fn associate_created_artifact( &self, ) -> AssociateCreatedArtifactFluentBuilder
Constructs a fluent builder for the AssociateCreatedArtifact operation.
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the ProgressUpdateStream.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueUnique identifier that references the migration task. Do not store personal data in this field.
created_artifact(CreatedArtifact)/set_created_artifact(Option<CreatedArtifact>):
required: trueAn ARN of the AWS resource related to the migration (e.g., AMI, EC2 instance, RDS instance, etc.)
dry_run(bool)/set_dry_run(Option<bool>):
required: falseOptional boolean flag to indicate whether any effect should take place. Used to test if the caller has permission to make the call.
- On success, responds with
AssociateCreatedArtifactOutput - On failure, responds with
SdkError<AssociateCreatedArtifactError>
Source§impl Client
impl Client
Sourcepub fn associate_discovered_resource(
&self,
) -> AssociateDiscoveredResourceFluentBuilder
pub fn associate_discovered_resource( &self, ) -> AssociateDiscoveredResourceFluentBuilder
Constructs a fluent builder for the AssociateDiscoveredResource operation.
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the ProgressUpdateStream.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueThe identifier given to the MigrationTask. Do not store personal data in this field.
discovered_resource(DiscoveredResource)/set_discovered_resource(Option<DiscoveredResource>):
required: trueObject representing a Resource.
dry_run(bool)/set_dry_run(Option<bool>):
required: falseOptional boolean flag to indicate whether any effect should take place. Used to test if the caller has permission to make the call.
- On success, responds with
AssociateDiscoveredResourceOutput - On failure, responds with
SdkError<AssociateDiscoveredResourceError>
Source§impl Client
impl Client
Sourcepub fn associate_source_resource(&self) -> AssociateSourceResourceFluentBuilder
pub fn associate_source_resource(&self) -> AssociateSourceResourceFluentBuilder
Constructs a fluent builder for the AssociateSourceResource operation.
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the progress-update stream, which is used for access control as well as a namespace for migration-task names that is implicitly linked to your AWS account. The progress-update stream must uniquely identify the migration tool as it is used for all updates made by the tool; however, it does not need to be unique for each AWS account because it is scoped to the AWS account.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueA unique identifier that references the migration task. Do not include sensitive data in this field.
source_resource(SourceResource)/set_source_resource(Option<SourceResource>):
required: trueThe source resource that you want to associate.
dry_run(bool)/set_dry_run(Option<bool>):
required: falseThis is an optional parameter that you can use to test whether the call will succeed. Set this parameter to
trueto verify that you have the permissions that are required to make the call, and that you have specified the other parameters in the call correctly.
- On success, responds with
AssociateSourceResourceOutput - On failure, responds with
SdkError<AssociateSourceResourceError>
Source§impl Client
impl Client
Sourcepub fn create_progress_update_stream(
&self,
) -> CreateProgressUpdateStreamFluentBuilder
pub fn create_progress_update_stream( &self, ) -> CreateProgressUpdateStreamFluentBuilder
Constructs a fluent builder for the CreateProgressUpdateStream operation.
- The fluent builder is configurable:
progress_update_stream_name(impl Into<String>)/set_progress_update_stream_name(Option<String>):
required: trueThe name of the ProgressUpdateStream. Do not store personal data in this field.
dry_run(bool)/set_dry_run(Option<bool>):
required: falseOptional boolean flag to indicate whether any effect should take place. Used to test if the caller has permission to make the call.
- On success, responds with
CreateProgressUpdateStreamOutput - On failure, responds with
SdkError<CreateProgressUpdateStreamError>
Source§impl Client
impl Client
Sourcepub fn delete_progress_update_stream(
&self,
) -> DeleteProgressUpdateStreamFluentBuilder
pub fn delete_progress_update_stream( &self, ) -> DeleteProgressUpdateStreamFluentBuilder
Constructs a fluent builder for the DeleteProgressUpdateStream operation.
- The fluent builder is configurable:
progress_update_stream_name(impl Into<String>)/set_progress_update_stream_name(Option<String>):
required: trueThe name of the ProgressUpdateStream. Do not store personal data in this field.
dry_run(bool)/set_dry_run(Option<bool>):
required: falseOptional boolean flag to indicate whether any effect should take place. Used to test if the caller has permission to make the call.
- On success, responds with
DeleteProgressUpdateStreamOutput - On failure, responds with
SdkError<DeleteProgressUpdateStreamError>
Source§impl Client
impl Client
Sourcepub fn describe_application_state(
&self,
) -> DescribeApplicationStateFluentBuilder
pub fn describe_application_state( &self, ) -> DescribeApplicationStateFluentBuilder
Constructs a fluent builder for the DescribeApplicationState operation.
- The fluent builder is configurable:
application_id(impl Into<String>)/set_application_id(Option<String>):
required: trueThe configurationId in Application Discovery Service that uniquely identifies the grouped application.
- On success, responds with
DescribeApplicationStateOutputwith field(s):application_status(Option<ApplicationStatus>):Status of the application - Not Started, In-Progress, Complete.
last_updated_time(Option<DateTime>):The timestamp when the application status was last updated.
- On failure, responds with
SdkError<DescribeApplicationStateError>
Source§impl Client
impl Client
Sourcepub fn describe_migration_task(&self) -> DescribeMigrationTaskFluentBuilder
pub fn describe_migration_task(&self) -> DescribeMigrationTaskFluentBuilder
Constructs a fluent builder for the DescribeMigrationTask operation.
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the ProgressUpdateStream.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueThe identifier given to the MigrationTask. Do not store personal data in this field.
- On success, responds with
DescribeMigrationTaskOutputwith field(s):migration_task(Option<MigrationTask>):Object encapsulating information about the migration task.
- On failure, responds with
SdkError<DescribeMigrationTaskError>
Source§impl Client
impl Client
Sourcepub fn disassociate_created_artifact(
&self,
) -> DisassociateCreatedArtifactFluentBuilder
pub fn disassociate_created_artifact( &self, ) -> DisassociateCreatedArtifactFluentBuilder
Constructs a fluent builder for the DisassociateCreatedArtifact operation.
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the ProgressUpdateStream.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueUnique identifier that references the migration task to be disassociated with the artifact. Do not store personal data in this field.
created_artifact_name(impl Into<String>)/set_created_artifact_name(Option<String>):
required: trueAn ARN of the AWS resource related to the migration (e.g., AMI, EC2 instance, RDS instance, etc.)
dry_run(bool)/set_dry_run(Option<bool>):
required: falseOptional boolean flag to indicate whether any effect should take place. Used to test if the caller has permission to make the call.
- On success, responds with
DisassociateCreatedArtifactOutput - On failure, responds with
SdkError<DisassociateCreatedArtifactError>
Source§impl Client
impl Client
Sourcepub fn disassociate_discovered_resource(
&self,
) -> DisassociateDiscoveredResourceFluentBuilder
pub fn disassociate_discovered_resource( &self, ) -> DisassociateDiscoveredResourceFluentBuilder
Constructs a fluent builder for the DisassociateDiscoveredResource operation.
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the ProgressUpdateStream.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueThe identifier given to the MigrationTask. Do not store personal data in this field.
configuration_id(impl Into<String>)/set_configuration_id(Option<String>):
required: trueConfigurationId of the Application Discovery Service resource to be disassociated.
dry_run(bool)/set_dry_run(Option<bool>):
required: falseOptional boolean flag to indicate whether any effect should take place. Used to test if the caller has permission to make the call.
- On success, responds with
DisassociateDiscoveredResourceOutput - On failure, responds with
SdkError<DisassociateDiscoveredResourceError>
Source§impl Client
impl Client
Sourcepub fn disassociate_source_resource(
&self,
) -> DisassociateSourceResourceFluentBuilder
pub fn disassociate_source_resource( &self, ) -> DisassociateSourceResourceFluentBuilder
Constructs a fluent builder for the DisassociateSourceResource operation.
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the progress-update stream, which is used for access control as well as a namespace for migration-task names that is implicitly linked to your AWS account. The progress-update stream must uniquely identify the migration tool as it is used for all updates made by the tool; however, it does not need to be unique for each AWS account because it is scoped to the AWS account.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueA unique identifier that references the migration task. Do not include sensitive data in this field.
source_resource_name(impl Into<String>)/set_source_resource_name(Option<String>):
required: trueThe name that was specified for the source resource.
dry_run(bool)/set_dry_run(Option<bool>):
required: falseThis is an optional parameter that you can use to test whether the call will succeed. Set this parameter to
trueto verify that you have the permissions that are required to make the call, and that you have specified the other parameters in the call correctly.
- On success, responds with
DisassociateSourceResourceOutput - On failure, responds with
SdkError<DisassociateSourceResourceError>
Source§impl Client
impl Client
Sourcepub fn import_migration_task(&self) -> ImportMigrationTaskFluentBuilder
pub fn import_migration_task(&self) -> ImportMigrationTaskFluentBuilder
Constructs a fluent builder for the ImportMigrationTask operation.
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the ProgressUpdateStream. >
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueUnique identifier that references the migration task. Do not store personal data in this field.
dry_run(bool)/set_dry_run(Option<bool>):
required: falseOptional boolean flag to indicate whether any effect should take place. Used to test if the caller has permission to make the call.
- On success, responds with
ImportMigrationTaskOutput - On failure, responds with
SdkError<ImportMigrationTaskError>
Source§impl Client
impl Client
Sourcepub fn list_application_states(&self) -> ListApplicationStatesFluentBuilder
pub fn list_application_states(&self) -> ListApplicationStatesFluentBuilder
Constructs a fluent builder for the ListApplicationStates operation.
This operation supports pagination; See into_paginator().
- The fluent builder is configurable:
application_ids(impl Into<String>)/set_application_ids(Option<Vec::<String>>):
required: falseThe configurationIds from the Application Discovery Service that uniquely identifies your applications.
next_token(impl Into<String>)/set_next_token(Option<String>):
required: falseIf a
NextTokenwas returned by a previous call, there are more results available. To retrieve the next page of results, make the call again using the returned token inNextToken.max_results(i32)/set_max_results(Option<i32>):
required: falseMaximum number of results to be returned per page.
- On success, responds with
ListApplicationStatesOutputwith field(s):application_state_list(Option<Vec::<ApplicationState>>):A list of Applications that exist in Application Discovery Service.
next_token(Option<String>):If a
NextTokenwas returned by a previous call, there are more results available. To retrieve the next page of results, make the call again using the returned token inNextToken.
- On failure, responds with
SdkError<ListApplicationStatesError>
Source§impl Client
impl Client
Sourcepub fn list_created_artifacts(&self) -> ListCreatedArtifactsFluentBuilder
pub fn list_created_artifacts(&self) -> ListCreatedArtifactsFluentBuilder
Constructs a fluent builder for the ListCreatedArtifacts operation.
This operation supports pagination; See into_paginator().
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the ProgressUpdateStream.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueUnique identifier that references the migration task. Do not store personal data in this field.
next_token(impl Into<String>)/set_next_token(Option<String>):
required: falseIf a
NextTokenwas returned by a previous call, there are more results available. To retrieve the next page of results, make the call again using the returned token inNextToken.max_results(i32)/set_max_results(Option<i32>):
required: falseMaximum number of results to be returned per page.
- On success, responds with
ListCreatedArtifactsOutputwith field(s):next_token(Option<String>):If there are more created artifacts than the max result, return the next token to be passed to the next call as a bookmark of where to start from.
created_artifact_list(Option<Vec::<CreatedArtifact>>):List of created artifacts up to the maximum number of results specified in the request.
- On failure, responds with
SdkError<ListCreatedArtifactsError>
Source§impl Client
impl Client
Sourcepub fn list_discovered_resources(&self) -> ListDiscoveredResourcesFluentBuilder
pub fn list_discovered_resources(&self) -> ListDiscoveredResourcesFluentBuilder
Constructs a fluent builder for the ListDiscoveredResources operation.
This operation supports pagination; See into_paginator().
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the ProgressUpdateStream.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueThe name of the MigrationTask. Do not store personal data in this field.
next_token(impl Into<String>)/set_next_token(Option<String>):
required: falseIf a
NextTokenwas returned by a previous call, there are more results available. To retrieve the next page of results, make the call again using the returned token inNextToken.max_results(i32)/set_max_results(Option<i32>):
required: falseThe maximum number of results returned per page.
- On success, responds with
ListDiscoveredResourcesOutputwith field(s):next_token(Option<String>):If there are more discovered resources than the max result, return the next token to be passed to the next call as a bookmark of where to start from.
discovered_resource_list(Option<Vec::<DiscoveredResource>>):Returned list of discovered resources associated with the given MigrationTask.
- On failure, responds with
SdkError<ListDiscoveredResourcesError>
Source§impl Client
impl Client
Sourcepub fn list_migration_task_updates(
&self,
) -> ListMigrationTaskUpdatesFluentBuilder
pub fn list_migration_task_updates( &self, ) -> ListMigrationTaskUpdatesFluentBuilder
Constructs a fluent builder for the ListMigrationTaskUpdates operation.
This operation supports pagination; See into_paginator().
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the progress-update stream, which is used for access control as well as a namespace for migration-task names that is implicitly linked to your AWS account. The progress-update stream must uniquely identify the migration tool as it is used for all updates made by the tool; however, it does not need to be unique for each AWS account because it is scoped to the AWS account.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueA unique identifier that references the migration task. Do not include sensitive data in this field.
next_token(impl Into<String>)/set_next_token(Option<String>):
required: falseIf
NextTokenwas returned by a previous call, there are more results available. The value ofNextTokenis a unique pagination token for each page. To retrieve the next page of results, specify theNextTokenvalue that the previous call returned. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error.max_results(i32)/set_max_results(Option<i32>):
required: falseThe maximum number of results to include in the response. If more results exist than the value that you specify here for
MaxResults, the response will include a token that you can use to retrieve the next set of results.
- On success, responds with
ListMigrationTaskUpdatesOutputwith field(s):next_token(Option<String>):If the response includes a
NextTokenvalue, that means that there are more results available. The value ofNextTokenis a unique pagination token for each page. To retrieve the next page of results, call this API again and specify thisNextTokenvalue in the request. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error.migration_task_update_list(Option<Vec::<MigrationTaskUpdate>>):The list of migration-task updates.
- On failure, responds with
SdkError<ListMigrationTaskUpdatesError>
Source§impl Client
impl Client
Sourcepub fn list_migration_tasks(&self) -> ListMigrationTasksFluentBuilder
pub fn list_migration_tasks(&self) -> ListMigrationTasksFluentBuilder
Constructs a fluent builder for the ListMigrationTasks operation.
This operation supports pagination; See into_paginator().
- The fluent builder is configurable:
next_token(impl Into<String>)/set_next_token(Option<String>):
required: falseIf a
NextTokenwas returned by a previous call, there are more results available. To retrieve the next page of results, make the call again using the returned token inNextToken.max_results(i32)/set_max_results(Option<i32>):
required: falseValue to specify how many results are returned per page.
resource_name(impl Into<String>)/set_resource_name(Option<String>):
required: falseFilter migration tasks by discovered resource name.
- On success, responds with
ListMigrationTasksOutputwith field(s):next_token(Option<String>):If there are more migration tasks than the max result, return the next token to be passed to the next call as a bookmark of where to start from.
migration_task_summary_list(Option<Vec::<MigrationTaskSummary>>):Lists the migration task’s summary which includes:
MigrationTaskName,ProgressPercent,ProgressUpdateStream,Status, and theUpdateDateTimefor each task.
- On failure, responds with
SdkError<ListMigrationTasksError>
Source§impl Client
impl Client
Sourcepub fn list_progress_update_streams(
&self,
) -> ListProgressUpdateStreamsFluentBuilder
pub fn list_progress_update_streams( &self, ) -> ListProgressUpdateStreamsFluentBuilder
Constructs a fluent builder for the ListProgressUpdateStreams operation.
This operation supports pagination; See into_paginator().
- The fluent builder is configurable:
next_token(impl Into<String>)/set_next_token(Option<String>):
required: falseIf a
NextTokenwas returned by a previous call, there are more results available. To retrieve the next page of results, make the call again using the returned token inNextToken.max_results(i32)/set_max_results(Option<i32>):
required: falseFilter to limit the maximum number of results to list per page.
- On success, responds with
ListProgressUpdateStreamsOutputwith field(s):progress_update_stream_summary_list(Option<Vec::<ProgressUpdateStreamSummary>>):List of progress update streams up to the max number of results passed in the input.
next_token(Option<String>):If there are more streams created than the max result, return the next token to be passed to the next call as a bookmark of where to start from.
- On failure, responds with
SdkError<ListProgressUpdateStreamsError>
Source§impl Client
impl Client
Sourcepub fn list_source_resources(&self) -> ListSourceResourcesFluentBuilder
pub fn list_source_resources(&self) -> ListSourceResourcesFluentBuilder
Constructs a fluent builder for the ListSourceResources operation.
This operation supports pagination; See into_paginator().
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the progress-update stream, which is used for access control as well as a namespace for migration-task names that is implicitly linked to your AWS account. The progress-update stream must uniquely identify the migration tool as it is used for all updates made by the tool; however, it does not need to be unique for each AWS account because it is scoped to the AWS account.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueA unique identifier that references the migration task. Do not store confidential data in this field.
next_token(impl Into<String>)/set_next_token(Option<String>):
required: falseIf
NextTokenwas returned by a previous call, there are more results available. The value ofNextTokenis a unique pagination token for each page. To retrieve the next page of results, specify theNextTokenvalue that the previous call returned. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error.max_results(i32)/set_max_results(Option<i32>):
required: falseThe maximum number of results to include in the response. If more results exist than the value that you specify here for
MaxResults, the response will include a token that you can use to retrieve the next set of results.
- On success, responds with
ListSourceResourcesOutputwith field(s):next_token(Option<String>):If the response includes a
NextTokenvalue, that means that there are more results available. The value ofNextTokenis a unique pagination token for each page. To retrieve the next page of results, call this API again and specify thisNextTokenvalue in the request. Keep all other arguments unchanged. Each pagination token expires after 24 hours. Using an expired pagination token will return an HTTP 400 InvalidToken error.source_resource_list(Option<Vec::<SourceResource>>):The list of source resources.
- On failure, responds with
SdkError<ListSourceResourcesError>
Source§impl Client
impl Client
Sourcepub fn notify_application_state(&self) -> NotifyApplicationStateFluentBuilder
pub fn notify_application_state(&self) -> NotifyApplicationStateFluentBuilder
Constructs a fluent builder for the NotifyApplicationState operation.
- The fluent builder is configurable:
application_id(impl Into<String>)/set_application_id(Option<String>):
required: trueThe configurationId in Application Discovery Service that uniquely identifies the grouped application.
status(ApplicationStatus)/set_status(Option<ApplicationStatus>):
required: trueStatus of the application - Not Started, In-Progress, Complete.
update_date_time(DateTime)/set_update_date_time(Option<DateTime>):
required: falseThe timestamp when the application state changed.
dry_run(bool)/set_dry_run(Option<bool>):
required: falseOptional boolean flag to indicate whether any effect should take place. Used to test if the caller has permission to make the call.
- On success, responds with
NotifyApplicationStateOutput - On failure, responds with
SdkError<NotifyApplicationStateError>
Source§impl Client
impl Client
Sourcepub fn notify_migration_task_state(
&self,
) -> NotifyMigrationTaskStateFluentBuilder
pub fn notify_migration_task_state( &self, ) -> NotifyMigrationTaskStateFluentBuilder
Constructs a fluent builder for the NotifyMigrationTaskState operation.
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the ProgressUpdateStream.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueUnique identifier that references the migration task. Do not store personal data in this field.
task(Task)/set_task(Option<Task>):
required: trueInformation about the task’s progress and status.
update_date_time(DateTime)/set_update_date_time(Option<DateTime>):
required: trueThe timestamp when the task was gathered.
next_update_seconds(i32)/set_next_update_seconds(Option<i32>):
required: trueNumber of seconds after the UpdateDateTime within which the Migration Hub can expect an update. If Migration Hub does not receive an update within the specified interval, then the migration task will be considered stale.
dry_run(bool)/set_dry_run(Option<bool>):
required: falseOptional boolean flag to indicate whether any effect should take place. Used to test if the caller has permission to make the call.
- On success, responds with
NotifyMigrationTaskStateOutput - On failure, responds with
SdkError<NotifyMigrationTaskStateError>
Source§impl Client
impl Client
Sourcepub fn put_resource_attributes(&self) -> PutResourceAttributesFluentBuilder
pub fn put_resource_attributes(&self) -> PutResourceAttributesFluentBuilder
Constructs a fluent builder for the PutResourceAttributes operation.
- The fluent builder is configurable:
progress_update_stream(impl Into<String>)/set_progress_update_stream(Option<String>):
required: trueThe name of the ProgressUpdateStream.
migration_task_name(impl Into<String>)/set_migration_task_name(Option<String>):
required: trueUnique identifier that references the migration task. Do not store personal data in this field.
resource_attribute_list(ResourceAttribute)/set_resource_attribute_list(Option<Vec::<ResourceAttribute>>):
required: trueInformation about the resource that is being migrated. This data will be used to map the task to a resource in the Application Discovery Service repository.
Takes the object array of
ResourceAttributewhere theTypefield is reserved for the following values:IPV4_ADDRESS | IPV6_ADDRESS | MAC_ADDRESS | FQDN | VM_MANAGER_ID | VM_MANAGED_OBJECT_REFERENCE | VM_NAME | VM_PATH | BIOS_ID | MOTHERBOARD_SERIAL_NUMBERwhere the identifying value can be a string up to 256 characters.-
If any “VM” related value is set for a
ResourceAttributeobject, it is required thatVM_MANAGER_ID, as a minimum, is always set. IfVM_MANAGER_IDis not set, then all “VM” fields will be discarded and “VM” fields will not be used for matching the migration task to a server in Application Discovery Service repository. See the Example section below for a use case of specifying “VM” related values. -
If a server you are trying to match has multiple IP or MAC addresses, you should provide as many as you know in separate type/value pairs passed to the
ResourceAttributeListparameter to maximize the chances of matching.
-
dry_run(bool)/set_dry_run(Option<bool>):
required: falseOptional boolean flag to indicate whether any effect should take place. Used to test if the caller has permission to make the call.
- On success, responds with
PutResourceAttributesOutput - On failure, responds with
SdkError<PutResourceAttributesError>
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);