Struct aws_sdk_backupgateway::client::Client
source · pub struct Client { /* private fields */ }
Expand description
Client for AWS Backup Gateway
Client for invoking operations on AWS Backup Gateway. Each operation on AWS Backup Gateway is a method on this
this struct. .send()
MUST be invoked on the generated operations to dispatch the request to the service.
Examples
Constructing a client and invoking an operation
// create a shared configuration. This can be used & shared between multiple service clients.
let shared_config = aws_config::load_from_env().await;
let client = aws_sdk_backupgateway::Client::new(&shared_config);
// invoke an operation
/* let rsp = client
.<operation_name>().
.<param>("some value")
.send().await; */
Constructing a client with custom configuration
use aws_config::retry::RetryConfig;
let shared_config = aws_config::load_from_env().await;
let config = aws_sdk_backupgateway::config::Builder::from(&shared_config)
.retry_config(RetryConfig::disabled())
.build();
let client = aws_sdk_backupgateway::Client::from_conf(config);
Implementations§
source§impl Client
impl Client
sourcepub fn with_config(
client: Client<DynConnector, DynMiddleware<DynConnector>>,
conf: Config
) -> Self
pub fn with_config(
client: Client<DynConnector, DynMiddleware<DynConnector>>,
conf: Config
) -> Self
Creates a client with the given service configuration.
source§impl Client
impl Client
sourcepub fn associate_gateway_to_server(&self) -> AssociateGatewayToServer
pub fn associate_gateway_to_server(&self) -> AssociateGatewayToServer
Constructs a fluent builder for the AssociateGatewayToServer
operation.
- The fluent builder is configurable:
gateway_arn(impl Into<String>)
/set_gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway. Use the
ListGateways
operation to return a list of gateways for your account and Amazon Web Services Region.server_arn(impl Into<String>)
/set_server_arn(Option<String>)
:The Amazon Resource Name (ARN) of the server that hosts your virtual machines.
- On success, responds with
AssociateGatewayToServerOutput
with field(s):gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of a gateway.
- On failure, responds with
SdkError<AssociateGatewayToServerError>
sourcepub fn create_gateway(&self) -> CreateGateway
pub fn create_gateway(&self) -> CreateGateway
Constructs a fluent builder for the CreateGateway
operation.
- The fluent builder is configurable:
activation_key(impl Into<String>)
/set_activation_key(Option<String>)
:The activation key of the created gateway.
gateway_display_name(impl Into<String>)
/set_gateway_display_name(Option<String>)
:The display name of the created gateway.
gateway_type(GatewayType)
/set_gateway_type(Option<GatewayType>)
:The type of created gateway.
tags(Vec<Tag>)
/set_tags(Option<Vec<Tag>>)
:A list of up to 50 tags to assign to the gateway. Each tag is a key-value pair.
- On success, responds with
CreateGatewayOutput
with field(s):gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway you create.
- On failure, responds with
SdkError<CreateGatewayError>
sourcepub fn delete_gateway(&self) -> DeleteGateway
pub fn delete_gateway(&self) -> DeleteGateway
Constructs a fluent builder for the DeleteGateway
operation.
- The fluent builder is configurable:
gateway_arn(impl Into<String>)
/set_gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway to delete.
- On success, responds with
DeleteGatewayOutput
with field(s):gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway you deleted.
- On failure, responds with
SdkError<DeleteGatewayError>
sourcepub fn delete_hypervisor(&self) -> DeleteHypervisor
pub fn delete_hypervisor(&self) -> DeleteHypervisor
Constructs a fluent builder for the DeleteHypervisor
operation.
- The fluent builder is configurable:
hypervisor_arn(impl Into<String>)
/set_hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor to delete.
- On success, responds with
DeleteHypervisorOutput
with field(s):hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor you deleted.
- On failure, responds with
SdkError<DeleteHypervisorError>
sourcepub fn disassociate_gateway_from_server(&self) -> DisassociateGatewayFromServer
pub fn disassociate_gateway_from_server(&self) -> DisassociateGatewayFromServer
Constructs a fluent builder for the DisassociateGatewayFromServer
operation.
- The fluent builder is configurable:
gateway_arn(impl Into<String>)
/set_gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway to disassociate.
- On success, responds with
DisassociateGatewayFromServerOutput
with field(s):gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway you disassociated.
- On failure, responds with
SdkError<DisassociateGatewayFromServerError>
sourcepub fn get_bandwidth_rate_limit_schedule(&self) -> GetBandwidthRateLimitSchedule
pub fn get_bandwidth_rate_limit_schedule(&self) -> GetBandwidthRateLimitSchedule
Constructs a fluent builder for the GetBandwidthRateLimitSchedule
operation.
- The fluent builder is configurable:
gateway_arn(impl Into<String>)
/set_gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway. Use the
ListGateways
operation to return a list of gateways for your account and Amazon Web Services Region.
- On success, responds with
GetBandwidthRateLimitScheduleOutput
with field(s):gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway. Use the
ListGateways
operation to return a list of gateways for your account and Amazon Web Services Region.bandwidth_rate_limit_intervals(Option<Vec<BandwidthRateLimitInterval>>)
:An array containing bandwidth rate limit schedule intervals for a gateway. When no bandwidth rate limit intervals have been scheduled, the array is empty.
- On failure, responds with
SdkError<GetBandwidthRateLimitScheduleError>
sourcepub fn get_gateway(&self) -> GetGateway
pub fn get_gateway(&self) -> GetGateway
Constructs a fluent builder for the GetGateway
operation.
- The fluent builder is configurable:
gateway_arn(impl Into<String>)
/set_gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway.
- On success, responds with
GetGatewayOutput
with field(s):gateway(Option<GatewayDetails>)
:By providing the ARN (Amazon Resource Name), this API returns the gateway.
- On failure, responds with
SdkError<GetGatewayError>
sourcepub fn get_hypervisor(&self) -> GetHypervisor
pub fn get_hypervisor(&self) -> GetHypervisor
Constructs a fluent builder for the GetHypervisor
operation.
- The fluent builder is configurable:
hypervisor_arn(impl Into<String>)
/set_hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor.
- On success, responds with
GetHypervisorOutput
with field(s):hypervisor(Option<HypervisorDetails>)
:Details about the requested hypervisor.
- On failure, responds with
SdkError<GetHypervisorError>
sourcepub fn get_hypervisor_property_mappings(&self) -> GetHypervisorPropertyMappings
pub fn get_hypervisor_property_mappings(&self) -> GetHypervisorPropertyMappings
Constructs a fluent builder for the GetHypervisorPropertyMappings
operation.
- The fluent builder is configurable:
hypervisor_arn(impl Into<String>)
/set_hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor.
- On success, responds with
GetHypervisorPropertyMappingsOutput
with field(s):hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor.
vmware_to_aws_tag_mappings(Option<Vec<VmwareToAwsTagMapping>>)
:This is a display of the mappings of on-premises VMware tags to the Amazon Web Services tags.
iam_role_arn(Option<String>)
:The Amazon Resource Name (ARN) of the IAM role.
- On failure, responds with
SdkError<GetHypervisorPropertyMappingsError>
sourcepub fn get_virtual_machine(&self) -> GetVirtualMachine
pub fn get_virtual_machine(&self) -> GetVirtualMachine
Constructs a fluent builder for the GetVirtualMachine
operation.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:The Amazon Resource Name (ARN) of the virtual machine.
- On success, responds with
GetVirtualMachineOutput
with field(s):virtual_machine(Option<VirtualMachineDetails>)
:This object contains the basic attributes of
VirtualMachine
contained by the output ofGetVirtualMachine
- On failure, responds with
SdkError<GetVirtualMachineError>
sourcepub fn import_hypervisor_configuration(&self) -> ImportHypervisorConfiguration
pub fn import_hypervisor_configuration(&self) -> ImportHypervisorConfiguration
Constructs a fluent builder for the ImportHypervisorConfiguration
operation.
- The fluent builder is configurable:
name(impl Into<String>)
/set_name(Option<String>)
:The name of the hypervisor.
host(impl Into<String>)
/set_host(Option<String>)
:The server host of the hypervisor. This can be either an IP address or a fully-qualified domain name (FQDN).
username(impl Into<String>)
/set_username(Option<String>)
:The username for the hypervisor.
password(impl Into<String>)
/set_password(Option<String>)
:The password for the hypervisor.
kms_key_arn(impl Into<String>)
/set_kms_key_arn(Option<String>)
:The Key Management Service for the hypervisor.
tags(Vec<Tag>)
/set_tags(Option<Vec<Tag>>)
:The tags of the hypervisor configuration to import.
- On success, responds with
ImportHypervisorConfigurationOutput
with field(s):hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor you disassociated.
- On failure, responds with
SdkError<ImportHypervisorConfigurationError>
sourcepub fn list_gateways(&self) -> ListGateways
pub fn list_gateways(&self) -> ListGateways
Constructs a fluent builder for the ListGateways
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
max_results(i32)
/set_max_results(Option<i32>)
:The maximum number of gateways to list.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:The next item following a partial list of returned resources. For example, if a request is made to return
MaxResults
number of resources,NextToken
allows you to return more items in your list starting at the location pointed to by the next token.
- On success, responds with
ListGatewaysOutput
with field(s):gateways(Option<Vec<Gateway>>)
:A list of your gateways.
next_token(Option<String>)
:The next item following a partial list of returned resources. For example, if a request is made to return
maxResults
number of resources,NextToken
allows you to return more items in your list starting at the location pointed to by the next token.
- On failure, responds with
SdkError<ListGatewaysError>
sourcepub fn list_hypervisors(&self) -> ListHypervisors
pub fn list_hypervisors(&self) -> ListHypervisors
Constructs a fluent builder for the ListHypervisors
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
max_results(i32)
/set_max_results(Option<i32>)
:The maximum number of hypervisors to list.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:The next item following a partial list of returned resources. For example, if a request is made to return
maxResults
number of resources,NextToken
allows you to return more items in your list starting at the location pointed to by the next token.
- On success, responds with
ListHypervisorsOutput
with field(s):hypervisors(Option<Vec<Hypervisor>>)
:A list of your
Hypervisor
objects, ordered by their Amazon Resource Names (ARNs).next_token(Option<String>)
:The next item following a partial list of returned resources. For example, if a request is made to return
maxResults
number of resources,NextToken
allows you to return more items in your list starting at the location pointed to by the next token.
- On failure, responds with
SdkError<ListHypervisorsError>
Constructs a fluent builder for the ListTagsForResource
operation.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:The Amazon Resource Name (ARN) of the resource’s tags to list.
- On success, responds with
ListTagsForResourceOutput
with field(s):resource_arn(Option<String>)
:The Amazon Resource Name (ARN) of the resource’s tags that you listed.
tags(Option<Vec<Tag>>)
:A list of the resource’s tags.
- On failure, responds with
SdkError<ListTagsForResourceError>
sourcepub fn list_virtual_machines(&self) -> ListVirtualMachines
pub fn list_virtual_machines(&self) -> ListVirtualMachines
Constructs a fluent builder for the ListVirtualMachines
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
hypervisor_arn(impl Into<String>)
/set_hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor connected to your virtual machine.
max_results(i32)
/set_max_results(Option<i32>)
:The maximum number of virtual machines to list.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:The next item following a partial list of returned resources. For example, if a request is made to return
maxResults
number of resources,NextToken
allows you to return more items in your list starting at the location pointed to by the next token.
- On success, responds with
ListVirtualMachinesOutput
with field(s):virtual_machines(Option<Vec<VirtualMachine>>)
:A list of your
VirtualMachine
objects, ordered by their Amazon Resource Names (ARNs).next_token(Option<String>)
:The next item following a partial list of returned resources. For example, if a request is made to return
maxResults
number of resources,NextToken
allows you to return more items in your list starting at the location pointed to by the next token.
- On failure, responds with
SdkError<ListVirtualMachinesError>
sourcepub fn put_bandwidth_rate_limit_schedule(&self) -> PutBandwidthRateLimitSchedule
pub fn put_bandwidth_rate_limit_schedule(&self) -> PutBandwidthRateLimitSchedule
Constructs a fluent builder for the PutBandwidthRateLimitSchedule
operation.
- The fluent builder is configurable:
gateway_arn(impl Into<String>)
/set_gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway. Use the
ListGateways
operation to return a list of gateways for your account and Amazon Web Services Region.bandwidth_rate_limit_intervals(Vec<BandwidthRateLimitInterval>)
/set_bandwidth_rate_limit_intervals(Option<Vec<BandwidthRateLimitInterval>>)
:An array containing bandwidth rate limit schedule intervals for a gateway. When no bandwidth rate limit intervals have been scheduled, the array is empty.
- On success, responds with
PutBandwidthRateLimitScheduleOutput
with field(s):gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway. Use the
ListGateways
operation to return a list of gateways for your account and Amazon Web Services Region.
- On failure, responds with
SdkError<PutBandwidthRateLimitScheduleError>
sourcepub fn put_hypervisor_property_mappings(&self) -> PutHypervisorPropertyMappings
pub fn put_hypervisor_property_mappings(&self) -> PutHypervisorPropertyMappings
Constructs a fluent builder for the PutHypervisorPropertyMappings
operation.
- The fluent builder is configurable:
hypervisor_arn(impl Into<String>)
/set_hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor.
vmware_to_aws_tag_mappings(Vec<VmwareToAwsTagMapping>)
/set_vmware_to_aws_tag_mappings(Option<Vec<VmwareToAwsTagMapping>>)
:This action requests the mappings of on-premises VMware tags to the Amazon Web Services tags.
iam_role_arn(impl Into<String>)
/set_iam_role_arn(Option<String>)
:The Amazon Resource Name (ARN) of the IAM role.
- On success, responds with
PutHypervisorPropertyMappingsOutput
with field(s):hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor.
- On failure, responds with
SdkError<PutHypervisorPropertyMappingsError>
sourcepub fn put_maintenance_start_time(&self) -> PutMaintenanceStartTime
pub fn put_maintenance_start_time(&self) -> PutMaintenanceStartTime
Constructs a fluent builder for the PutMaintenanceStartTime
operation.
- The fluent builder is configurable:
gateway_arn(impl Into<String>)
/set_gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) for the gateway, used to specify its maintenance start time.
hour_of_day(i32)
/set_hour_of_day(Option<i32>)
:The hour of the day to start maintenance on a gateway.
minute_of_hour(i32)
/set_minute_of_hour(Option<i32>)
:The minute of the hour to start maintenance on a gateway.
day_of_week(i32)
/set_day_of_week(Option<i32>)
:The day of the week to start maintenance on a gateway.
day_of_month(i32)
/set_day_of_month(Option<i32>)
:The day of the month start maintenance on a gateway.
Valid values range from
Sunday
toSaturday
.
- On success, responds with
PutMaintenanceStartTimeOutput
with field(s):gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of a gateway for which you set the maintenance start time.
- On failure, responds with
SdkError<PutMaintenanceStartTimeError>
sourcepub fn start_virtual_machines_metadata_sync(
&self
) -> StartVirtualMachinesMetadataSync
pub fn start_virtual_machines_metadata_sync(
&self
) -> StartVirtualMachinesMetadataSync
Constructs a fluent builder for the StartVirtualMachinesMetadataSync
operation.
- The fluent builder is configurable:
hypervisor_arn(impl Into<String>)
/set_hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor.
- On success, responds with
StartVirtualMachinesMetadataSyncOutput
with field(s):hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor.
- On failure, responds with
SdkError<StartVirtualMachinesMetadataSyncError>
sourcepub fn tag_resource(&self) -> TagResource
pub fn tag_resource(&self) -> TagResource
Constructs a fluent builder for the TagResource
operation.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:The Amazon Resource Name (ARN) of the resource to tag.
tags(Vec<Tag>)
/set_tags(Option<Vec<Tag>>)
:A list of tags to assign to the resource.
- On success, responds with
TagResourceOutput
with field(s):resource_arn(Option<String>)
:The Amazon Resource Name (ARN) of the resource you tagged.
- On failure, responds with
SdkError<TagResourceError>
sourcepub fn test_hypervisor_configuration(&self) -> TestHypervisorConfiguration
pub fn test_hypervisor_configuration(&self) -> TestHypervisorConfiguration
Constructs a fluent builder for the TestHypervisorConfiguration
operation.
- The fluent builder is configurable:
gateway_arn(impl Into<String>)
/set_gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway to the hypervisor to test.
host(impl Into<String>)
/set_host(Option<String>)
:The server host of the hypervisor. This can be either an IP address or a fully-qualified domain name (FQDN).
username(impl Into<String>)
/set_username(Option<String>)
:The username for the hypervisor.
password(impl Into<String>)
/set_password(Option<String>)
:The password for the hypervisor.
- On success, responds with
TestHypervisorConfigurationOutput
- On failure, responds with
SdkError<TestHypervisorConfigurationError>
sourcepub fn untag_resource(&self) -> UntagResource
pub fn untag_resource(&self) -> UntagResource
Constructs a fluent builder for the UntagResource
operation.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:The Amazon Resource Name (ARN) of the resource from which to remove tags.
tag_keys(Vec<String>)
/set_tag_keys(Option<Vec<String>>)
:The list of tag keys specifying which tags to remove.
- On success, responds with
UntagResourceOutput
with field(s):resource_arn(Option<String>)
:The Amazon Resource Name (ARN) of the resource from which you removed tags.
- On failure, responds with
SdkError<UntagResourceError>
sourcepub fn update_gateway_information(&self) -> UpdateGatewayInformation
pub fn update_gateway_information(&self) -> UpdateGatewayInformation
Constructs a fluent builder for the UpdateGatewayInformation
operation.
- The fluent builder is configurable:
gateway_arn(impl Into<String>)
/set_gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway to update.
gateway_display_name(impl Into<String>)
/set_gateway_display_name(Option<String>)
:The updated display name of the gateway.
- On success, responds with
UpdateGatewayInformationOutput
with field(s):gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway you updated.
- On failure, responds with
SdkError<UpdateGatewayInformationError>
sourcepub fn update_gateway_software_now(&self) -> UpdateGatewaySoftwareNow
pub fn update_gateway_software_now(&self) -> UpdateGatewaySoftwareNow
Constructs a fluent builder for the UpdateGatewaySoftwareNow
operation.
- The fluent builder is configurable:
gateway_arn(impl Into<String>)
/set_gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway to be updated.
- On success, responds with
UpdateGatewaySoftwareNowOutput
with field(s):gateway_arn(Option<String>)
:The Amazon Resource Name (ARN) of the gateway you updated.
- On failure, responds with
SdkError<UpdateGatewaySoftwareNowError>
sourcepub fn update_hypervisor(&self) -> UpdateHypervisor
pub fn update_hypervisor(&self) -> UpdateHypervisor
Constructs a fluent builder for the UpdateHypervisor
operation.
- The fluent builder is configurable:
hypervisor_arn(impl Into<String>)
/set_hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor to update.
host(impl Into<String>)
/set_host(Option<String>)
:The updated host of the hypervisor. This can be either an IP address or a fully-qualified domain name (FQDN).
username(impl Into<String>)
/set_username(Option<String>)
:The updated username for the hypervisor.
password(impl Into<String>)
/set_password(Option<String>)
:The updated password for the hypervisor.
name(impl Into<String>)
/set_name(Option<String>)
:The updated name for the hypervisor
log_group_arn(impl Into<String>)
/set_log_group_arn(Option<String>)
:The Amazon Resource Name (ARN) of the group of gateways within the requested log.
- On success, responds with
UpdateHypervisorOutput
with field(s):hypervisor_arn(Option<String>)
:The Amazon Resource Name (ARN) of the hypervisor you updated.
- On failure, responds with
SdkError<UpdateHypervisorError>
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_config
is missing an async sleep implementation. If you experience this panic, set thesleep_impl
on the Config passed into this function to fix it. - This method will panic if the
sdk_config
is missing an HTTP connector. If you experience this panic, set thehttp_connector
on the Config passed into this function to fix it.
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 if the
conf
is missing an async sleep implementation. If you experience this panic, set thesleep_impl
on the Config passed into this function to fix it. - This method will panic if the
conf
is missing an HTTP connector. If you experience this panic, set thehttp_connector
on the Config passed into this function to fix it.