Struct aws_sdk_datasync::Client
source · pub struct Client { /* private fields */ }
Expand description
Client for AWS DataSync
Client for invoking operations on AWS DataSync. Each operation on AWS DataSync 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_datasync::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_datasync::config::Builder::from(&shared_config)
.retry_config(RetryConfig::disabled())
.build();
let client = aws_sdk_datasync::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 cancel_task_execution(&self) -> CancelTaskExecution
pub fn cancel_task_execution(&self) -> CancelTaskExecution
Constructs a fluent builder for the CancelTaskExecution
operation.
- The fluent builder is configurable:
task_execution_arn(impl Into<String>)
/set_task_execution_arn(Option<String>)
:The Amazon Resource Name (ARN) of the task execution to stop.
- On success, responds with
CancelTaskExecutionOutput
- On failure, responds with
SdkError<CancelTaskExecutionError>
sourcepub fn create_agent(&self) -> CreateAgent
pub fn create_agent(&self) -> CreateAgent
Constructs a fluent builder for the CreateAgent
operation.
- The fluent builder is configurable:
activation_key(impl Into<String>)
/set_activation_key(Option<String>)
:Your agent activation key. You can get the activation key either by sending an HTTP GET request with redirects that enable you to get the agent IP address (port 80). Alternatively, you can get it from the DataSync console.
The redirect URL returned in the response provides you the activation key for your agent in the query string parameter
activationKey
. It might also include other activation-related parameters; however, these are merely defaults. The arguments you pass to this API call determine the actual configuration of your agent.For more information, see Activating an Agent in the DataSync User Guide.
agent_name(impl Into<String>)
/set_agent_name(Option<String>)
:The name you configured for your agent. This value is a text reference that is used to identify the agent in the console.
tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:The key-value pair that represents the tag that you want to associate with the agent. The value can be an empty string. This value helps you manage, filter, and search for your agents.
Valid characters for key and value are letters, spaces, and numbers representable in UTF-8 format, and the following special characters: + - = . _ : / @.
vpc_endpoint_id(impl Into<String>)
/set_vpc_endpoint_id(Option<String>)
:The ID of the VPC (virtual private cloud) endpoint that the agent has access to. This is the client-side VPC endpoint, also called a PrivateLink. If you don’t have a PrivateLink VPC endpoint, see Creating a VPC Endpoint Service Configuration in the Amazon VPC User Guide.
VPC endpoint ID looks like this:
vpce-01234d5aff67890e1
.subnet_arns(Vec<String>)
/set_subnet_arns(Option<Vec<String>>)
:The Amazon Resource Names (ARNs) of the subnets in which DataSync will create elastic network interfaces for each data transfer task. The agent that runs a task must be private. When you start a task that is associated with an agent created in a VPC, or one that has access to an IP address in a VPC, then the task is also private. In this case, DataSync creates four network interfaces for each task in your subnet. For a data transfer to work, the agent must be able to route to all these four network interfaces.
security_group_arns(Vec<String>)
/set_security_group_arns(Option<Vec<String>>)
:The ARNs of the security groups used to protect your data transfer task subnets. See SecurityGroupArns.
- On success, responds with
CreateAgentOutput
with field(s):agent_arn(Option<String>)
:The Amazon Resource Name (ARN) of the agent. Use the
ListAgents
operation to return a list of agents for your account and Amazon Web Services Region.
- On failure, responds with
SdkError<CreateAgentError>
sourcepub fn create_location_efs(&self) -> CreateLocationEfs
pub fn create_location_efs(&self) -> CreateLocationEfs
Constructs a fluent builder for the CreateLocationEfs
operation.
- The fluent builder is configurable:
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:Specifies a mount path for your Amazon EFS file system. This is where DataSync reads or writes data (depending on if this is a source or destination location). By default, DataSync uses the root directory, but you can also include subdirectories.
You must specify a value with forward slashes (for example,
/path/to/folder
).efs_filesystem_arn(impl Into<String>)
/set_efs_filesystem_arn(Option<String>)
:Specifies the ARN for the Amazon EFS file system.
ec2_config(Ec2Config)
/set_ec2_config(Option<Ec2Config>)
:Specifies the subnet and security groups DataSync uses to access your Amazon EFS file system.
tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:Specifies the key-value pair that represents a tag that you want to add to the resource. The value can be an empty string. This value helps you manage, filter, and search for your resources. We recommend that you create a name tag for your location.
access_point_arn(impl Into<String>)
/set_access_point_arn(Option<String>)
:Specifies the Amazon Resource Name (ARN) of the access point that DataSync uses to access the Amazon EFS file system.
file_system_access_role_arn(impl Into<String>)
/set_file_system_access_role_arn(Option<String>)
:Specifies an Identity and Access Management (IAM) role that DataSync assumes when mounting the Amazon EFS file system.
in_transit_encryption(EfsInTransitEncryption)
/set_in_transit_encryption(Option<EfsInTransitEncryption>)
:Specifies whether you want DataSync to use Transport Layer Security (TLS) 1.2 encryption when it copies data to or from the Amazon EFS file system.
If you specify an access point using
AccessPointArn
or an IAM role usingFileSystemAccessRoleArn
, you must set this parameter toTLS1_2
.
- On success, responds with
CreateLocationEfsOutput
with field(s):location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the Amazon EFS file system location that you create.
- On failure, responds with
SdkError<CreateLocationEfsError>
sourcepub fn create_location_fsx_lustre(&self) -> CreateLocationFsxLustre
pub fn create_location_fsx_lustre(&self) -> CreateLocationFsxLustre
Constructs a fluent builder for the CreateLocationFsxLustre
operation.
- The fluent builder is configurable:
fsx_filesystem_arn(impl Into<String>)
/set_fsx_filesystem_arn(Option<String>)
:The Amazon Resource Name (ARN) for the FSx for Lustre file system.
security_group_arns(Vec<String>)
/set_security_group_arns(Option<Vec<String>>)
:The Amazon Resource Names (ARNs) of the security groups that are used to configure the FSx for Lustre file system.
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:A subdirectory in the location’s path. This subdirectory in the FSx for Lustre file system is used to read data from the FSx for Lustre source location or write data to the FSx for Lustre destination.
tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:The key-value pair that represents a tag that you want to add to the resource. The value can be an empty string. This value helps you manage, filter, and search for your resources. We recommend that you create a name tag for your location.
- On success, responds with
CreateLocationFsxLustreOutput
with field(s):location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the FSx for Lustre file system location that’s created.
- On failure, responds with
SdkError<CreateLocationFsxLustreError>
sourcepub fn create_location_fsx_ontap(&self) -> CreateLocationFsxOntap
pub fn create_location_fsx_ontap(&self) -> CreateLocationFsxOntap
Constructs a fluent builder for the CreateLocationFsxOntap
operation.
- The fluent builder is configurable:
protocol(FsxProtocol)
/set_protocol(Option<FsxProtocol>)
:Specifies the data transfer protocol that DataSync uses to access your Amazon FSx file system.
security_group_arns(Vec<String>)
/set_security_group_arns(Option<Vec<String>>)
:Specifies the Amazon EC2 security groups that provide access to your file system’s preferred subnet.
The security groups must allow outbound traffic on the following ports (depending on the protocol you use):
-
Network File System (NFS): TCP ports 111, 635, and 2049
-
Server Message Block (SMB): TCP port 445
Your file system’s security groups must also allow inbound traffic on the same ports.
-
storage_virtual_machine_arn(impl Into<String>)
/set_storage_virtual_machine_arn(Option<String>)
:Specifies the ARN of the storage virtual machine (SVM) on your file system where you’re copying data to or from.
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:Specifies the junction path (also known as a mount point) in the SVM volume where you’re copying data to or from (for example,
/vol1
).Don’t specify a junction path in the SVM’s root volume. For more information, see Managing FSx for ONTAP storage virtual machines in the Amazon FSx for NetApp ONTAP User Guide.
tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:Specifies labels that help you categorize, filter, and search for your Amazon Web Services resources. We recommend creating at least a name tag for your location.
- On success, responds with
CreateLocationFsxOntapOutput
with field(s):location_arn(Option<String>)
:Specifies the ARN of the FSx for ONTAP file system location that you create.
- On failure, responds with
SdkError<CreateLocationFsxOntapError>
sourcepub fn create_location_fsx_open_zfs(&self) -> CreateLocationFsxOpenZfs
pub fn create_location_fsx_open_zfs(&self) -> CreateLocationFsxOpenZfs
Constructs a fluent builder for the CreateLocationFsxOpenZfs
operation.
- The fluent builder is configurable:
fsx_filesystem_arn(impl Into<String>)
/set_fsx_filesystem_arn(Option<String>)
:The Amazon Resource Name (ARN) of the FSx for OpenZFS file system.
protocol(FsxProtocol)
/set_protocol(Option<FsxProtocol>)
:The type of protocol that DataSync uses to access your file system.
security_group_arns(Vec<String>)
/set_security_group_arns(Option<Vec<String>>)
:The ARNs of the security groups that are used to configure the FSx for OpenZFS file system.
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:A subdirectory in the location’s path that must begin with
/fsx
. DataSync uses this subdirectory to read or write data (depending on whether the file system is a source or destination location).tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:The key-value pair that represents a tag that you want to add to the resource. The value can be an empty string. This value helps you manage, filter, and search for your resources. We recommend that you create a name tag for your location.
- On success, responds with
CreateLocationFsxOpenZfsOutput
with field(s):location_arn(Option<String>)
:The ARN of the FSx for OpenZFS file system location that you created.
- On failure, responds with
SdkError<CreateLocationFsxOpenZfsError>
sourcepub fn create_location_fsx_windows(&self) -> CreateLocationFsxWindows
pub fn create_location_fsx_windows(&self) -> CreateLocationFsxWindows
Constructs a fluent builder for the CreateLocationFsxWindows
operation.
- The fluent builder is configurable:
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:Specifies a mount path for your file system using forward slashes. This is where DataSync reads or writes data (depending on if this is a source or destination location).
fsx_filesystem_arn(impl Into<String>)
/set_fsx_filesystem_arn(Option<String>)
:Specifies the Amazon Resource Name (ARN) for the FSx for Windows File Server file system.
security_group_arns(Vec<String>)
/set_security_group_arns(Option<Vec<String>>)
:Specifies the ARNs of the security groups that provide access to your file system’s preferred subnet.
If you choose a security group that doesn’t allow connections from within itself, do one of the following:
-
Configure the security group to allow it to communicate within itself.
-
Choose a different security group that can communicate with the mount target’s security group.
-
tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:Specifies labels that help you categorize, filter, and search for your Amazon Web Services resources. We recommend creating at least a name tag for your location.
user(impl Into<String>)
/set_user(Option<String>)
:Specifies the user who has the permissions to access files and folders in the file system.
For information about choosing a user name that ensures sufficient permissions to files, folders, and metadata, see user.
domain(impl Into<String>)
/set_domain(Option<String>)
:Specifies the name of the Windows domain that the FSx for Windows File Server belongs to.
password(impl Into<String>)
/set_password(Option<String>)
:Specifies the password of the user who has the permissions to access files and folders in the file system.
- On success, responds with
CreateLocationFsxWindowsOutput
with field(s):location_arn(Option<String>)
:The ARN of the FSx for Windows File Server file system location you created.
- On failure, responds with
SdkError<CreateLocationFsxWindowsError>
sourcepub fn create_location_hdfs(&self) -> CreateLocationHdfs
pub fn create_location_hdfs(&self) -> CreateLocationHdfs
Constructs a fluent builder for the CreateLocationHdfs
operation.
- The fluent builder is configurable:
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:A subdirectory in the HDFS cluster. This subdirectory is used to read data from or write data to the HDFS cluster. If the subdirectory isn’t specified, it will default to
/
.name_nodes(Vec<HdfsNameNode>)
/set_name_nodes(Option<Vec<HdfsNameNode>>)
:The NameNode that manages the HDFS namespace. The NameNode performs operations such as opening, closing, and renaming files and directories. The NameNode contains the information to map blocks of data to the DataNodes. You can use only one NameNode.
block_size(i32)
/set_block_size(Option<i32>)
:The size of data blocks to write into the HDFS cluster. The block size must be a multiple of 512 bytes. The default block size is 128 mebibytes (MiB).
replication_factor(i32)
/set_replication_factor(Option<i32>)
:The number of DataNodes to replicate the data to when writing to the HDFS cluster. By default, data is replicated to three DataNodes.
kms_key_provider_uri(impl Into<String>)
/set_kms_key_provider_uri(Option<String>)
:The URI of the HDFS cluster’s Key Management Server (KMS).
qop_configuration(QopConfiguration)
/set_qop_configuration(Option<QopConfiguration>)
:The Quality of Protection (QOP) configuration specifies the Remote Procedure Call (RPC) and data transfer protection settings configured on the Hadoop Distributed File System (HDFS) cluster. If
QopConfiguration
isn’t specified,RpcProtection
andDataTransferProtection
default toPRIVACY
. If you setRpcProtection
orDataTransferProtection
, the other parameter assumes the same value.authentication_type(HdfsAuthenticationType)
/set_authentication_type(Option<HdfsAuthenticationType>)
:The type of authentication used to determine the identity of the user.
simple_user(impl Into<String>)
/set_simple_user(Option<String>)
:The user name used to identify the client on the host operating system.
If
SIMPLE
is specified forAuthenticationType
, this parameter is required.kerberos_principal(impl Into<String>)
/set_kerberos_principal(Option<String>)
:The Kerberos principal with access to the files and folders on the HDFS cluster.
If
KERBEROS
is specified forAuthenticationType
, this parameter is required.kerberos_keytab(Blob)
/set_kerberos_keytab(Option<Blob>)
:The Kerberos key table (keytab) that contains mappings between the defined Kerberos principal and the encrypted keys. You can load the keytab from a file by providing the file’s address. If you’re using the CLI, it performs base64 encoding for you. Otherwise, provide the base64-encoded text.
If
KERBEROS
is specified forAuthenticationType
, this parameter is required.kerberos_krb5_conf(Blob)
/set_kerberos_krb5_conf(Option<Blob>)
:The
krb5.conf
file that contains the Kerberos configuration information. You can load thekrb5.conf
file by providing the file’s address. If you’re using the CLI, it performs the base64 encoding for you. Otherwise, provide the base64-encoded text.If
KERBEROS
is specified forAuthenticationType
, this parameter is required.agent_arns(Vec<String>)
/set_agent_arns(Option<Vec<String>>)
:The Amazon Resource Names (ARNs) of the agents that are used to connect to the HDFS cluster.
tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:The key-value pair that represents the tag that you want to add to the location. The value can be an empty string. We recommend using tags to name your resources.
- On success, responds with
CreateLocationHdfsOutput
with field(s):location_arn(Option<String>)
:The ARN of the source HDFS cluster location that’s created.
- On failure, responds with
SdkError<CreateLocationHdfsError>
sourcepub fn create_location_nfs(&self) -> CreateLocationNfs
pub fn create_location_nfs(&self) -> CreateLocationNfs
Constructs a fluent builder for the CreateLocationNfs
operation.
- The fluent builder is configurable:
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:The subdirectory in the NFS file system that is used to read data from the NFS source location or write data to the NFS destination. The NFS path should be a path that’s exported by the NFS server, or a subdirectory of that path. The path should be such that it can be mounted by other NFS clients in your network.
To see all the paths exported by your NFS server, run “
showmount -e nfs-server-name
” from an NFS client that has access to your server. You can specify any directory that appears in the results, and any subdirectory of that directory. Ensure that the NFS export is accessible without Kerberos authentication.To transfer all the data in the folder you specified, DataSync needs to have permissions to read all the data. To ensure this, either configure the NFS export with
no_root_squash,
or ensure that the permissions for all of the files that you want DataSync allow read access for all users. Doing either enables the agent to read the files. For the agent to access directories, you must additionally enable all execute access.If you are copying data to or from your Snowcone device, see NFS Server on Snowcone for more information.
For information about NFS export configuration, see 18.7. The /etc/exports Configuration File in the Red Hat Enterprise Linux documentation.
server_hostname(impl Into<String>)
/set_server_hostname(Option<String>)
:The name of the NFS server. This value is the IP address or Domain Name Service (DNS) name of the NFS server. An agent that is installed on-premises uses this hostname to mount the NFS server in a network.
If you are copying data to or from your Snowcone device, see NFS Server on Snowcone for more information.
This name must either be DNS-compliant or must be an IP version 4 (IPv4) address.
on_prem_config(OnPremConfig)
/set_on_prem_config(Option<OnPremConfig>)
:Contains a list of Amazon Resource Names (ARNs) of agents that are used to connect to an NFS server.
If you are copying data to or from your Snowcone device, see NFS Server on Snowcone for more information.
mount_options(NfsMountOptions)
/set_mount_options(Option<NfsMountOptions>)
:The NFS mount options that DataSync can use to mount your NFS share.
tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:The key-value pair that represents the tag that you want to add to the location. The value can be an empty string. We recommend using tags to name your resources.
- On success, responds with
CreateLocationNfsOutput
with field(s):location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the source NFS file system location that is created.
- On failure, responds with
SdkError<CreateLocationNfsError>
sourcepub fn create_location_object_storage(&self) -> CreateLocationObjectStorage
pub fn create_location_object_storage(&self) -> CreateLocationObjectStorage
Constructs a fluent builder for the CreateLocationObjectStorage
operation.
- The fluent builder is configurable:
server_hostname(impl Into<String>)
/set_server_hostname(Option<String>)
:Specifies the domain name or IP address of the object storage server. A DataSync agent uses this hostname to mount the object storage server in a network.
server_port(i32)
/set_server_port(Option<i32>)
:Specifies the port that your object storage server accepts inbound network traffic on (for example, port 443).
server_protocol(ObjectStorageServerProtocol)
/set_server_protocol(Option<ObjectStorageServerProtocol>)
:Specifies the protocol that your object storage server uses to communicate.
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:Specifies the object prefix for your object storage server. If this is a source location, DataSync only copies objects with this prefix. If this is a destination location, DataSync writes all objects with this prefix.
bucket_name(impl Into<String>)
/set_bucket_name(Option<String>)
:Specifies the name of the object storage bucket involved in the transfer.
access_key(impl Into<String>)
/set_access_key(Option<String>)
:Specifies the access key (for example, a user name) if credentials are required to authenticate with the object storage server.
secret_key(impl Into<String>)
/set_secret_key(Option<String>)
:Specifies the secret key (for example, a password) if credentials are required to authenticate with the object storage server.
agent_arns(Vec<String>)
/set_agent_arns(Option<Vec<String>>)
:Specifies the Amazon Resource Names (ARNs) of the DataSync agents that can securely connect with your location.
tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:Specifies the key-value pair that represents a tag that you want to add to the resource. Tags can help you manage, filter, and search for your resources. We recommend creating a name tag for your location.
server_certificate(Blob)
/set_server_certificate(Option<Blob>)
:Specifies a certificate to authenticate with an object storage system that uses a private or self-signed certificate authority (CA). You must specify a Base64-encoded
.pem
file (for example,file:///home/user/.ssh/storage_sys_certificate.pem
). The certificate can be up to 32768 bytes (before Base64 encoding).To use this parameter, configure
ServerProtocol
toHTTPS
.
- On success, responds with
CreateLocationObjectStorageOutput
with field(s):location_arn(Option<String>)
:Specifies the ARN of the object storage system location that you create.
- On failure, responds with
SdkError<CreateLocationObjectStorageError>
sourcepub fn create_location_s3(&self) -> CreateLocationS3
pub fn create_location_s3(&self) -> CreateLocationS3
Constructs a fluent builder for the CreateLocationS3
operation.
- The fluent builder is configurable:
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:A subdirectory in the Amazon S3 bucket. This subdirectory in Amazon S3 is used to read data from the S3 source location or write data to the S3 destination.
s3_bucket_arn(impl Into<String>)
/set_s3_bucket_arn(Option<String>)
:The ARN of the Amazon S3 bucket. If the bucket is on an Amazon Web Services Outpost, this must be an access point ARN.
s3_storage_class(S3StorageClass)
/set_s3_storage_class(Option<S3StorageClass>)
:The Amazon S3 storage class that you want to store your files in when this location is used as a task destination. For buckets in Amazon Web Services Regions, the storage class defaults to Standard. For buckets on Outposts, the storage class defaults to Amazon Web Services S3 Outposts.
For more information about S3 storage classes, see Amazon S3 Storage Classes. Some storage classes have behaviors that can affect your S3 storage cost. For detailed information, see Considerations when working with S3 storage classes in DataSync.
s3_config(S3Config)
/set_s3_config(Option<S3Config>)
:The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role used to access an Amazon S3 bucket.
For detailed information about using such a role, see Creating a Location for Amazon S3 in the DataSync User Guide.
agent_arns(Vec<String>)
/set_agent_arns(Option<Vec<String>>)
:If you’re using DataSync on an Amazon Web Services Outpost, specify the Amazon Resource Names (ARNs) of the DataSync agents deployed on your Outpost. For more information about launching a DataSync agent on an Amazon Web Services Outpost, see Deploy your DataSync agent on Outposts.
tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:The key-value pair that represents the tag that you want to add to the location. The value can be an empty string. We recommend using tags to name your resources.
- On success, responds with
CreateLocationS3Output
with field(s):location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the source Amazon S3 bucket location that is created.
- On failure, responds with
SdkError<CreateLocationS3Error>
sourcepub fn create_location_smb(&self) -> CreateLocationSmb
pub fn create_location_smb(&self) -> CreateLocationSmb
Constructs a fluent builder for the CreateLocationSmb
operation.
- The fluent builder is configurable:
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:The subdirectory in the SMB file system that is used to read data from the SMB source location or write data to the SMB destination. The SMB path should be a path that’s exported by the SMB server, or a subdirectory of that path. The path should be such that it can be mounted by other SMB clients in your network.
Subdirectory
must be specified with forward slashes. For example,/path/to/folder
.To transfer all the data in the folder you specified, DataSync needs to have permissions to mount the SMB share, as well as to access all the data in that share. To ensure this, either ensure that the user/password specified belongs to the user who can mount the share, and who has the appropriate permissions for all of the files and directories that you want DataSync to access, or use credentials of a member of the Backup Operators group to mount the share. Doing either enables the agent to access the data. For the agent to access directories, you must additionally enable all execute access.
server_hostname(impl Into<String>)
/set_server_hostname(Option<String>)
:The name of the SMB server. This value is the IP address or Domain Name Service (DNS) name of the SMB server. An agent that is installed on-premises uses this hostname to mount the SMB server in a network.
This name must either be DNS-compliant or must be an IP version 4 (IPv4) address.
user(impl Into<String>)
/set_user(Option<String>)
:The user who can mount the share, has the permissions to access files and folders in the SMB share.
For information about choosing a user name that ensures sufficient permissions to files, folders, and metadata, see the User setting for SMB locations.
domain(impl Into<String>)
/set_domain(Option<String>)
:The name of the Windows domain that the SMB server belongs to.
password(impl Into<String>)
/set_password(Option<String>)
:The password of the user who can mount the share, has the permissions to access files and folders in the SMB share.
agent_arns(Vec<String>)
/set_agent_arns(Option<Vec<String>>)
:The Amazon Resource Names (ARNs) of agents to use for a Simple Message Block (SMB) location.
mount_options(SmbMountOptions)
/set_mount_options(Option<SmbMountOptions>)
:The mount options used by DataSync to access the SMB server.
tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:The key-value pair that represents the tag that you want to add to the location. The value can be an empty string. We recommend using tags to name your resources.
- On success, responds with
CreateLocationSmbOutput
with field(s):location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the source SMB file system location that is created.
- On failure, responds with
SdkError<CreateLocationSmbError>
sourcepub fn create_task(&self) -> CreateTask
pub fn create_task(&self) -> CreateTask
Constructs a fluent builder for the CreateTask
operation.
- The fluent builder is configurable:
source_location_arn(impl Into<String>)
/set_source_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the source location for the task.
destination_location_arn(impl Into<String>)
/set_destination_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of an Amazon Web Services storage resource’s location.
cloud_watch_log_group_arn(impl Into<String>)
/set_cloud_watch_log_group_arn(Option<String>)
:The Amazon Resource Name (ARN) of the Amazon CloudWatch log group that is used to monitor and log events in the task.
name(impl Into<String>)
/set_name(Option<String>)
:The name of a task. This value is a text reference that is used to identify the task in the console.
options(Options)
/set_options(Option<Options>)
:Specifies the configuration options for a task. Some options include preserving file or object metadata and verifying data integrity.
You can also override these options before starting an individual run of a task (also known as a task execution). For more information, see StartTaskExecution.
excludes(Vec<FilterRule>)
/set_excludes(Option<Vec<FilterRule>>)
:Specifies a list of filter rules that exclude specific data during your transfer. For more information and examples, see Filtering data transferred by DataSync.
schedule(TaskSchedule)
/set_schedule(Option<TaskSchedule>)
:Specifies a schedule used to periodically transfer files from a source to a destination location. The schedule should be specified in UTC time. For more information, see Scheduling your task.
tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:Specifies the tags that you want to apply to the Amazon Resource Name (ARN) representing the task.
Tags are key-value pairs that help you manage, filter, and search for your DataSync resources.
includes(Vec<FilterRule>)
/set_includes(Option<Vec<FilterRule>>)
:Specifies a list of filter rules that include specific data during your transfer. For more information and examples, see Filtering data transferred by DataSync.
- On success, responds with
CreateTaskOutput
with field(s):task_arn(Option<String>)
:The Amazon Resource Name (ARN) of the task.
- On failure, responds with
SdkError<CreateTaskError>
sourcepub fn delete_agent(&self) -> DeleteAgent
pub fn delete_agent(&self) -> DeleteAgent
Constructs a fluent builder for the DeleteAgent
operation.
- The fluent builder is configurable:
agent_arn(impl Into<String>)
/set_agent_arn(Option<String>)
:The Amazon Resource Name (ARN) of the agent to delete. Use the
ListAgents
operation to return a list of agents for your account and Amazon Web Services Region.
- On success, responds with
DeleteAgentOutput
- On failure, responds with
SdkError<DeleteAgentError>
sourcepub fn delete_location(&self) -> DeleteLocation
pub fn delete_location(&self) -> DeleteLocation
Constructs a fluent builder for the DeleteLocation
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the location to delete.
- On success, responds with
DeleteLocationOutput
- On failure, responds with
SdkError<DeleteLocationError>
sourcepub fn delete_task(&self) -> DeleteTask
pub fn delete_task(&self) -> DeleteTask
Constructs a fluent builder for the DeleteTask
operation.
- The fluent builder is configurable:
task_arn(impl Into<String>)
/set_task_arn(Option<String>)
:Specifies the Amazon Resource Name (ARN) of the task that you want to delete.
- On success, responds with
DeleteTaskOutput
- On failure, responds with
SdkError<DeleteTaskError>
sourcepub fn describe_agent(&self) -> DescribeAgent
pub fn describe_agent(&self) -> DescribeAgent
Constructs a fluent builder for the DescribeAgent
operation.
- The fluent builder is configurable:
agent_arn(impl Into<String>)
/set_agent_arn(Option<String>)
:The Amazon Resource Name (ARN) of the agent to describe.
- On success, responds with
DescribeAgentOutput
with field(s):agent_arn(Option<String>)
:The Amazon Resource Name (ARN) of the agent.
name(Option<String>)
:The name of the agent.
status(Option<AgentStatus>)
:The status of the agent. If the status is ONLINE, then the agent is configured properly and is available to use. The Running status is the normal running status for an agent. If the status is OFFLINE, the agent’s VM is turned off or the agent is in an unhealthy state. When the issue that caused the unhealthy state is resolved, the agent returns to ONLINE status.
last_connection_time(Option<DateTime>)
:The time that the agent last connected to DataSync.
creation_time(Option<DateTime>)
:The time that the agent was activated (that is, created in your account).
endpoint_type(Option<EndpointType>)
:The type of endpoint that your agent is connected to. If the endpoint is a VPC endpoint, the agent is not accessible over the public internet.
private_link_config(Option<PrivateLinkConfig>)
:The subnet and the security group that DataSync used to access a VPC endpoint.
- On failure, responds with
SdkError<DescribeAgentError>
sourcepub fn describe_location_efs(&self) -> DescribeLocationEfs
pub fn describe_location_efs(&self) -> DescribeLocationEfs
Constructs a fluent builder for the DescribeLocationEfs
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the Amazon EFS file system location that you want information about.
- On success, responds with
DescribeLocationEfsOutput
with field(s):location_arn(Option<String>)
:The ARN of the Amazon EFS file system location.
location_uri(Option<String>)
:The URL of the Amazon EFS file system location.
ec2_config(Option<Ec2Config>)
:The subnet and security groups that DataSync uses to access your Amazon EFS file system.
creation_time(Option<DateTime>)
:The time that the location was created.
access_point_arn(Option<String>)
:The ARN of the access point that DataSync uses to access the Amazon EFS file system.
file_system_access_role_arn(Option<String>)
:The Identity and Access Management (IAM) role that DataSync assumes when mounting the Amazon EFS file system.
in_transit_encryption(Option<EfsInTransitEncryption>)
:Describes whether DataSync uses Transport Layer Security (TLS) encryption when copying data to or from the Amazon EFS file system.
- On failure, responds with
SdkError<DescribeLocationEfsError>
sourcepub fn describe_location_fsx_lustre(&self) -> DescribeLocationFsxLustre
pub fn describe_location_fsx_lustre(&self) -> DescribeLocationFsxLustre
Constructs a fluent builder for the DescribeLocationFsxLustre
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the FSx for Lustre location to describe.
- On success, responds with
DescribeLocationFsxLustreOutput
with field(s):location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the FSx for Lustre location that was described.
location_uri(Option<String>)
:The URI of the FSx for Lustre location that was described.
security_group_arns(Option<Vec<String>>)
:The Amazon Resource Names (ARNs) of the security groups that are configured for the FSx for Lustre file system.
creation_time(Option<DateTime>)
:The time that the FSx for Lustre location was created.
- On failure, responds with
SdkError<DescribeLocationFsxLustreError>
sourcepub fn describe_location_fsx_ontap(&self) -> DescribeLocationFsxOntap
pub fn describe_location_fsx_ontap(&self) -> DescribeLocationFsxOntap
Constructs a fluent builder for the DescribeLocationFsxOntap
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:Specifies the Amazon Resource Name (ARN) of the FSx for ONTAP file system location that you want information about.
- On success, responds with
DescribeLocationFsxOntapOutput
with field(s):creation_time(Option<DateTime>)
:The time that the location was created.
location_arn(Option<String>)
:The ARN of the FSx for ONTAP file system location.
location_uri(Option<String>)
:The uniform resource identifier (URI) of the FSx for ONTAP file system location.
protocol(Option<FsxProtocol>)
:Specifies the data transfer protocol that DataSync uses to access your Amazon FSx file system.
security_group_arns(Option<Vec<String>>)
:The security groups that DataSync uses to access your FSx for ONTAP file system.
storage_virtual_machine_arn(Option<String>)
:The ARN of the storage virtual machine (SVM) on your FSx for ONTAP file system where you’re copying data to or from.
fsx_filesystem_arn(Option<String>)
:The ARN of the FSx for ONTAP file system.
- On failure, responds with
SdkError<DescribeLocationFsxOntapError>
sourcepub fn describe_location_fsx_open_zfs(&self) -> DescribeLocationFsxOpenZfs
pub fn describe_location_fsx_open_zfs(&self) -> DescribeLocationFsxOpenZfs
Constructs a fluent builder for the DescribeLocationFsxOpenZfs
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the FSx for OpenZFS location to describe.
- On success, responds with
DescribeLocationFsxOpenZfsOutput
with field(s):location_arn(Option<String>)
:The ARN of the FSx for OpenZFS location that was described.
location_uri(Option<String>)
:The uniform resource identifier (URI) of the FSx for OpenZFS location that was described.
Example:
fsxz://us-west-2.fs-1234567890abcdef02/fsx/folderA/folder
security_group_arns(Option<Vec<String>>)
:The ARNs of the security groups that are configured for the FSx for OpenZFS file system.
protocol(Option<FsxProtocol>)
:The type of protocol that DataSync uses to access your file system.
creation_time(Option<DateTime>)
:The time that the FSx for OpenZFS location was created.
- On failure, responds with
SdkError<DescribeLocationFsxOpenZfsError>
sourcepub fn describe_location_fsx_windows(&self) -> DescribeLocationFsxWindows
pub fn describe_location_fsx_windows(&self) -> DescribeLocationFsxWindows
Constructs a fluent builder for the DescribeLocationFsxWindows
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the FSx for Windows File Server location to describe.
- On success, responds with
DescribeLocationFsxWindowsOutput
with field(s):location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the FSx for Windows File Server location that was described.
location_uri(Option<String>)
:The URL of the FSx for Windows File Server location that was described.
security_group_arns(Option<Vec<String>>)
:The Amazon Resource Names (ARNs) of the security groups that are configured for the FSx for Windows File Server file system.
creation_time(Option<DateTime>)
:The time that the FSx for Windows File Server location was created.
user(Option<String>)
:The user who has the permissions to access files and folders in the FSx for Windows File Server file system.
domain(Option<String>)
:The name of the Windows domain that the FSx for Windows File Server belongs to.
- On failure, responds with
SdkError<DescribeLocationFsxWindowsError>
sourcepub fn describe_location_hdfs(&self) -> DescribeLocationHdfs
pub fn describe_location_hdfs(&self) -> DescribeLocationHdfs
Constructs a fluent builder for the DescribeLocationHdfs
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the HDFS cluster location to describe.
- On success, responds with
DescribeLocationHdfsOutput
with field(s):location_arn(Option<String>)
:The ARN of the HDFS cluster location.
location_uri(Option<String>)
:The URI of the HDFS cluster location.
name_nodes(Option<Vec<HdfsNameNode>>)
:The NameNode that manage the HDFS namespace.
block_size(Option<i32>)
:The size of the data blocks to write into the HDFS cluster.
replication_factor(Option<i32>)
:The number of DataNodes to replicate the data to when writing to the HDFS cluster.
kms_key_provider_uri(Option<String>)
:The URI of the HDFS cluster’s Key Management Server (KMS).
qop_configuration(Option<QopConfiguration>)
:The Quality of Protection (QOP) configuration specifies the Remote Procedure Call (RPC) and data transfer protection settings configured on the Hadoop Distributed File System (HDFS) cluster.
authentication_type(Option<HdfsAuthenticationType>)
:The type of authentication used to determine the identity of the user.
simple_user(Option<String>)
:The user name used to identify the client on the host operating system. This parameter is used if the
AuthenticationType
is defined asSIMPLE
.kerberos_principal(Option<String>)
:The Kerberos principal with access to the files and folders on the HDFS cluster. This parameter is used if the
AuthenticationType
is defined asKERBEROS
.agent_arns(Option<Vec<String>>)
:The ARNs of the agents that are used to connect to the HDFS cluster.
creation_time(Option<DateTime>)
:The time that the HDFS location was created.
- On failure, responds with
SdkError<DescribeLocationHdfsError>
sourcepub fn describe_location_nfs(&self) -> DescribeLocationNfs
pub fn describe_location_nfs(&self) -> DescribeLocationNfs
Constructs a fluent builder for the DescribeLocationNfs
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the NFS location to describe.
- On success, responds with
DescribeLocationNfsOutput
with field(s):location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the NFS location that was described.
location_uri(Option<String>)
:The URL of the source NFS location that was described.
on_prem_config(Option<OnPremConfig>)
:A list of Amazon Resource Names (ARNs) of agents to use for a Network File System (NFS) location.
mount_options(Option<NfsMountOptions>)
:The NFS mount options that DataSync used to mount your NFS share.
creation_time(Option<DateTime>)
:The time that the NFS location was created.
- On failure, responds with
SdkError<DescribeLocationNfsError>
sourcepub fn describe_location_object_storage(&self) -> DescribeLocationObjectStorage
pub fn describe_location_object_storage(&self) -> DescribeLocationObjectStorage
Constructs a fluent builder for the DescribeLocationObjectStorage
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the object storage system location that you want information about.
- On success, responds with
DescribeLocationObjectStorageOutput
with field(s):location_arn(Option<String>)
:The ARN of the object storage system location.
location_uri(Option<String>)
:The URL of the object storage system location.
access_key(Option<String>)
:The access key (for example, a user name) required to authenticate with the object storage system.
server_port(Option<i32>)
:The port that your object storage server accepts inbound network traffic on (for example, port 443).
server_protocol(Option<ObjectStorageServerProtocol>)
:The protocol that your object storage system uses to communicate.
agent_arns(Option<Vec<String>>)
:The ARNs of the DataSync agents that can securely connect with your location.
creation_time(Option<DateTime>)
:The time that the location was created.
server_certificate(Option<Blob>)
:The self-signed certificate that DataSync uses to securely authenticate with your object storage system.
- On failure, responds with
SdkError<DescribeLocationObjectStorageError>
sourcepub fn describe_location_s3(&self) -> DescribeLocationS3
pub fn describe_location_s3(&self) -> DescribeLocationS3
Constructs a fluent builder for the DescribeLocationS3
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the Amazon S3 bucket location to describe.
- On success, responds with
DescribeLocationS3Output
with field(s):location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the Amazon S3 bucket or access point.
location_uri(Option<String>)
:The URL of the Amazon S3 location that was described.
s3_storage_class(Option<S3StorageClass>)
:The Amazon S3 storage class that you chose to store your files in when this location is used as a task destination. For more information about S3 storage classes, see Amazon S3 Storage Classes. Some storage classes have behaviors that can affect your S3 storage cost. For detailed information, see Considerations when working with S3 storage classes in DataSync.
s3_config(Option<S3Config>)
:The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role used to access an Amazon S3 bucket.
For detailed information about using such a role, see Creating a Location for Amazon S3 in the DataSync User Guide.
agent_arns(Option<Vec<String>>)
:If you are using DataSync on an Amazon Web Services Outpost, the Amazon Resource Name (ARNs) of the EC2 agents deployed on your Outpost. For more information about launching a DataSync agent on an Amazon Web Services Outpost, see Deploy your DataSync agent on Outposts.
creation_time(Option<DateTime>)
:The time that the Amazon S3 bucket location was created.
- On failure, responds with
SdkError<DescribeLocationS3Error>
sourcepub fn describe_location_smb(&self) -> DescribeLocationSmb
pub fn describe_location_smb(&self) -> DescribeLocationSmb
Constructs a fluent builder for the DescribeLocationSmb
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the SMB location to describe.
- On success, responds with
DescribeLocationSmbOutput
with field(s):location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the SMB location that was described.
location_uri(Option<String>)
:The URL of the source SMB location that was described.
agent_arns(Option<Vec<String>>)
:The Amazon Resource Name (ARN) of the source SMB file system location that is created.
user(Option<String>)
:The user who can mount the share, has the permissions to access files and folders in the SMB share.
domain(Option<String>)
:The name of the Windows domain that the SMB server belongs to.
mount_options(Option<SmbMountOptions>)
:The mount options that are available for DataSync to use to access an SMB location.
creation_time(Option<DateTime>)
:The time that the SMB location was created.
- On failure, responds with
SdkError<DescribeLocationSmbError>
sourcepub fn describe_task(&self) -> DescribeTask
pub fn describe_task(&self) -> DescribeTask
Constructs a fluent builder for the DescribeTask
operation.
- The fluent builder is configurable:
task_arn(impl Into<String>)
/set_task_arn(Option<String>)
:The Amazon Resource Name (ARN) of the task to describe.
- On success, responds with
DescribeTaskOutput
with field(s):task_arn(Option<String>)
:The Amazon Resource Name (ARN) of the task that was described.
status(Option<TaskStatus>)
:The status of the task that was described.
For detailed information about task execution statuses, see Understanding Task Statuses in the DataSync User Guide.
name(Option<String>)
:The name of the task that was described.
current_task_execution_arn(Option<String>)
:The Amazon Resource Name (ARN) of the task execution that is transferring files.
source_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the source file system’s location.
destination_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the Amazon Web Services storage resource’s location.
cloud_watch_log_group_arn(Option<String>)
:The Amazon Resource Name (ARN) of the Amazon CloudWatch log group that was used to monitor and log events in the task.
For more information on these groups, see Working with Log Groups and Log Streams in the Amazon CloudWatch User Guide.
source_network_interface_arns(Option<Vec<String>>)
:The Amazon Resource Names (ARNs) of the network interfaces created for your source location. For more information, see Network interface requirements.
destination_network_interface_arns(Option<Vec<String>>)
:The Amazon Resource Names (ARNs) of the network interfaces created for your destination location. For more information, see Network interface requirements.
options(Option<Options>)
:The configuration options that control the behavior of the
StartTaskExecution
operation. Some options include preserving file or object metadata and verifying data integrity.You can override these options for each task execution. For more information, see StartTaskExecution.
excludes(Option<Vec<FilterRule>>)
:A list of filter rules that exclude specific data during your transfer. For more information and examples, see Filtering data transferred by DataSync.
schedule(Option<TaskSchedule>)
:The schedule used to periodically transfer files from a source to a destination location.
error_code(Option<String>)
:Errors that DataSync encountered during execution of the task. You can use this error code to help troubleshoot issues.
error_detail(Option<String>)
:Detailed description of an error that was encountered during the task execution. You can use this information to help troubleshoot issues.
creation_time(Option<DateTime>)
:The time that the task was created.
includes(Option<Vec<FilterRule>>)
:A list of filter rules that include specific data during your transfer. For more information and examples, see Filtering data transferred by DataSync.
- On failure, responds with
SdkError<DescribeTaskError>
sourcepub fn describe_task_execution(&self) -> DescribeTaskExecution
pub fn describe_task_execution(&self) -> DescribeTaskExecution
Constructs a fluent builder for the DescribeTaskExecution
operation.
- The fluent builder is configurable:
task_execution_arn(impl Into<String>)
/set_task_execution_arn(Option<String>)
:The Amazon Resource Name (ARN) of the task that is being executed.
- On success, responds with
DescribeTaskExecutionOutput
with field(s):task_execution_arn(Option<String>)
:The Amazon Resource Name (ARN) of the task execution that was described.
TaskExecutionArn
is hierarchical and includesTaskArn
for the task that was executed.For example, a
TaskExecution
value with the ARNarn:aws:datasync:us-east-1:111222333444:task/task-0208075f79cedf4a2/execution/exec-08ef1e88ec491019b
executed the task with the ARNarn:aws:datasync:us-east-1:111222333444:task/task-0208075f79cedf4a2
.status(Option<TaskExecutionStatus>)
:The status of the task execution.
For detailed information about task execution statuses, see Understanding Task Statuses in the DataSync User Guide.
options(Option<Options>)
:Configures your DataSync task settings. These options include how DataSync handles files, objects, and their associated metadata. You also can specify how DataSync verifies data integrity, set bandwidth limits for your task, among other options.
Each task setting has a default value. Unless you need to, you don’t have to configure any of these
Options
before starting your task.excludes(Option<Vec<FilterRule>>)
:A list of filter rules that exclude specific data during your transfer. For more information and examples, see Filtering data transferred by DataSync.
includes(Option<Vec<FilterRule>>)
:A list of filter rules that include specific data during your transfer. For more information and examples, see Filtering data transferred by DataSync.
start_time(Option<DateTime>)
:The time that the task execution was started.
estimated_files_to_transfer(i64)
:The expected number of files that is to be transferred over the network. This value is calculated during the
PREPARING
phase before theTRANSFERRING
phase of the task execution. This value is the expected number of files to be transferred. It’s calculated based on comparing the content of the source and destination locations and finding the delta that needs to be transferred.estimated_bytes_to_transfer(i64)
:The estimated physical number of bytes that is to be transferred over the network.
files_transferred(i64)
:The actual number of files that was transferred over the network. This value is calculated and updated on an ongoing basis during the
TRANSFERRING
phase of the task execution. It’s updated periodically when each file is read from the source and sent over the network.If failures occur during a transfer, this value can be less than
EstimatedFilesToTransfer
. In some cases, this value can also be greater thanEstimatedFilesToTransfer
. This element is implementation-specific for some location types, so don’t use it as an indicator for a correct file number or to monitor your task execution.bytes_written(i64)
:The number of logical bytes written to the destination Amazon Web Services storage resource.
bytes_transferred(i64)
:The total number of bytes that are involved in the transfer. For the number of bytes sent over the network, see
BytesCompressed
.result(Option<TaskExecutionResultDetail>)
:The result of the task execution.
bytes_compressed(i64)
:The physical number of bytes transferred over the network after compression was applied. In most cases, this number is less than
BytesTransferred
unless the data isn’t compressible.
- On failure, responds with
SdkError<DescribeTaskExecutionError>
sourcepub fn list_agents(&self) -> ListAgents
pub fn list_agents(&self) -> ListAgents
Constructs a fluent builder for the ListAgents
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 agents to list.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:An opaque string that indicates the position at which to begin the next list of agents.
- On success, responds with
ListAgentsOutput
with field(s):agents(Option<Vec<AgentListEntry>>)
:A list of agents in your account.
next_token(Option<String>)
:An opaque string that indicates the position at which to begin returning the next list of agents.
- On failure, responds with
SdkError<ListAgentsError>
sourcepub fn list_locations(&self) -> ListLocations
pub fn list_locations(&self) -> ListLocations
Constructs a fluent builder for the ListLocations
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 locations to return.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:An opaque string that indicates the position at which to begin the next list of locations.
filters(Vec<LocationFilter>)
/set_filters(Option<Vec<LocationFilter>>)
:You can use API filters to narrow down the list of resources returned by
ListLocations
. For example, to retrieve all tasks on a specific source location, you can useListLocations
with filter nameLocationType S3
andOperator Equals
.
- On success, responds with
ListLocationsOutput
with field(s):locations(Option<Vec<LocationListEntry>>)
:An array that contains a list of locations.
next_token(Option<String>)
:An opaque string that indicates the position at which to begin returning the next list of locations.
- On failure, responds with
SdkError<ListLocationsError>
Constructs a fluent builder for the ListTagsForResource
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
resource_arn(impl Into<String>)
/set_resource_arn(Option<String>)
:Specifies the Amazon Resource Name (ARN) of the resource that you want tag information on.
max_results(i32)
/set_max_results(Option<i32>)
:Specifies how many results that you want in the response.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:Specifies an opaque string that indicates the position to begin the next list of results in the response.
- On success, responds with
ListTagsForResourceOutput
with field(s):tags(Option<Vec<TagListEntry>>)
:An array of tags applied to the specified resource.
next_token(Option<String>)
:The opaque string that indicates the position to begin the next list of results in the response.
- On failure, responds with
SdkError<ListTagsForResourceError>
sourcepub fn list_task_executions(&self) -> ListTaskExecutions
pub fn list_task_executions(&self) -> ListTaskExecutions
Constructs a fluent builder for the ListTaskExecutions
operation.
This operation supports pagination; See into_paginator()
.
- The fluent builder is configurable:
task_arn(impl Into<String>)
/set_task_arn(Option<String>)
:The Amazon Resource Name (ARN) of the task whose tasks you want to list.
max_results(i32)
/set_max_results(Option<i32>)
:The maximum number of executed tasks to list.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:An opaque string that indicates the position at which to begin the next list of the executed tasks.
- On success, responds with
ListTaskExecutionsOutput
with field(s):task_executions(Option<Vec<TaskExecutionListEntry>>)
:A list of executed tasks.
next_token(Option<String>)
:An opaque string that indicates the position at which to begin returning the next list of executed tasks.
- On failure, responds with
SdkError<ListTaskExecutionsError>
sourcepub fn list_tasks(&self) -> ListTasks
pub fn list_tasks(&self) -> ListTasks
Constructs a fluent builder for the ListTasks
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 tasks to return.
next_token(impl Into<String>)
/set_next_token(Option<String>)
:An opaque string that indicates the position at which to begin the next list of tasks.
filters(Vec<TaskFilter>)
/set_filters(Option<Vec<TaskFilter>>)
:You can use API filters to narrow down the list of resources returned by
ListTasks
. For example, to retrieve all tasks on a specific source location, you can useListTasks
with filter nameLocationId
andOperator Equals
with the ARN for the location.
- On success, responds with
ListTasksOutput
with field(s):tasks(Option<Vec<TaskListEntry>>)
:A list of all the tasks that are returned.
next_token(Option<String>)
:An opaque string that indicates the position at which to begin returning the next list of tasks.
- On failure, responds with
SdkError<ListTasksError>
sourcepub fn start_task_execution(&self) -> StartTaskExecution
pub fn start_task_execution(&self) -> StartTaskExecution
Constructs a fluent builder for the StartTaskExecution
operation.
- The fluent builder is configurable:
task_arn(impl Into<String>)
/set_task_arn(Option<String>)
:Specifies the Amazon Resource Name (ARN) of the task that you want to start.
override_options(Options)
/set_override_options(Option<Options>)
:Configures your DataSync task settings. These options include how DataSync handles files, objects, and their associated metadata. You also can specify how DataSync verifies data integrity, set bandwidth limits for your task, among other options.
Each task setting has a default value. Unless you need to, you don’t have to configure any of these
Options
before starting your task.includes(Vec<FilterRule>)
/set_includes(Option<Vec<FilterRule>>)
:Specifies a list of filter rules that determines which files to include when running a task. The pattern should contain a single filter string that consists of the patterns to include. The patterns are delimited by “|” (that is, a pipe), for example,
“/folder1|/folder2”
.excludes(Vec<FilterRule>)
/set_excludes(Option<Vec<FilterRule>>)
:Specifies a list of filter rules that determines which files to exclude from a task. The list contains a single filter string that consists of the patterns to exclude. The patterns are delimited by “|” (that is, a pipe), for example,
“/folder1|/folder2”
.tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:Specifies the tags that you want to apply to the Amazon Resource Name (ARN) representing the task execution.
Tags are key-value pairs that help you manage, filter, and search for your DataSync resources.
- On success, responds with
StartTaskExecutionOutput
with field(s):task_execution_arn(Option<String>)
:The ARN of the running task execution.
- On failure, responds with
SdkError<StartTaskExecutionError>
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>)
:Specifies the Amazon Resource Name (ARN) of the resource to apply the tag to.
tags(Vec<TagListEntry>)
/set_tags(Option<Vec<TagListEntry>>)
:Specifies the tags that you want to apply to the resource.
- On success, responds with
TagResourceOutput
- On failure, responds with
SdkError<TagResourceError>
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>)
:Specifies the Amazon Resource Name (ARN) of the resource to remove the tags from.
keys(Vec<String>)
/set_keys(Option<Vec<String>>)
:Specifies the keys in the tags that you want to remove.
- On success, responds with
UntagResourceOutput
- On failure, responds with
SdkError<UntagResourceError>
sourcepub fn update_agent(&self) -> UpdateAgent
pub fn update_agent(&self) -> UpdateAgent
Constructs a fluent builder for the UpdateAgent
operation.
- The fluent builder is configurable:
agent_arn(impl Into<String>)
/set_agent_arn(Option<String>)
:The Amazon Resource Name (ARN) of the agent to update.
name(impl Into<String>)
/set_name(Option<String>)
:The name that you want to use to configure the agent.
- On success, responds with
UpdateAgentOutput
- On failure, responds with
SdkError<UpdateAgentError>
sourcepub fn update_location_hdfs(&self) -> UpdateLocationHdfs
pub fn update_location_hdfs(&self) -> UpdateLocationHdfs
Constructs a fluent builder for the UpdateLocationHdfs
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the source HDFS cluster location.
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:A subdirectory in the HDFS cluster. This subdirectory is used to read data from or write data to the HDFS cluster.
name_nodes(Vec<HdfsNameNode>)
/set_name_nodes(Option<Vec<HdfsNameNode>>)
:The NameNode that manages the HDFS namespace. The NameNode performs operations such as opening, closing, and renaming files and directories. The NameNode contains the information to map blocks of data to the DataNodes. You can use only one NameNode.
block_size(i32)
/set_block_size(Option<i32>)
:The size of the data blocks to write into the HDFS cluster.
replication_factor(i32)
/set_replication_factor(Option<i32>)
:The number of DataNodes to replicate the data to when writing to the HDFS cluster.
kms_key_provider_uri(impl Into<String>)
/set_kms_key_provider_uri(Option<String>)
:The URI of the HDFS cluster’s Key Management Server (KMS).
qop_configuration(QopConfiguration)
/set_qop_configuration(Option<QopConfiguration>)
:The Quality of Protection (QOP) configuration specifies the Remote Procedure Call (RPC) and data transfer privacy settings configured on the Hadoop Distributed File System (HDFS) cluster.
authentication_type(HdfsAuthenticationType)
/set_authentication_type(Option<HdfsAuthenticationType>)
:The type of authentication used to determine the identity of the user.
simple_user(impl Into<String>)
/set_simple_user(Option<String>)
:The user name used to identify the client on the host operating system.
kerberos_principal(impl Into<String>)
/set_kerberos_principal(Option<String>)
:The Kerberos principal with access to the files and folders on the HDFS cluster.
kerberos_keytab(Blob)
/set_kerberos_keytab(Option<Blob>)
:The Kerberos key table (keytab) that contains mappings between the defined Kerberos principal and the encrypted keys. You can load the keytab from a file by providing the file’s address. If you use the CLI, it performs base64 encoding for you. Otherwise, provide the base64-encoded text.
kerberos_krb5_conf(Blob)
/set_kerberos_krb5_conf(Option<Blob>)
:The
krb5.conf
file that contains the Kerberos configuration information. You can load thekrb5.conf
file by providing the file’s address. If you’re using the CLI, it performs the base64 encoding for you. Otherwise, provide the base64-encoded text.agent_arns(Vec<String>)
/set_agent_arns(Option<Vec<String>>)
:The ARNs of the agents that are used to connect to the HDFS cluster.
- On success, responds with
UpdateLocationHdfsOutput
- On failure, responds with
SdkError<UpdateLocationHdfsError>
sourcepub fn update_location_nfs(&self) -> UpdateLocationNfs
pub fn update_location_nfs(&self) -> UpdateLocationNfs
Constructs a fluent builder for the UpdateLocationNfs
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the NFS location to update.
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:The subdirectory in the NFS file system that is used to read data from the NFS source location or write data to the NFS destination. The NFS path should be a path that’s exported by the NFS server, or a subdirectory of that path. The path should be such that it can be mounted by other NFS clients in your network.
To see all the paths exported by your NFS server, run “
showmount -e nfs-server-name
” from an NFS client that has access to your server. You can specify any directory that appears in the results, and any subdirectory of that directory. Ensure that the NFS export is accessible without Kerberos authentication.To transfer all the data in the folder that you specified, DataSync must have permissions to read all the data. To ensure this, either configure the NFS export with
no_root_squash
, or ensure that the files you want DataSync to access have permissions that allow read access for all users. Doing either option enables the agent to read the files. For the agent to access directories, you must additionally enable all execute access.If you are copying data to or from your Snowcone device, see NFS Server on Snowcone for more information.
For information about NFS export configuration, see 18.7. The /etc/exports Configuration File in the Red Hat Enterprise Linux documentation.
on_prem_config(OnPremConfig)
/set_on_prem_config(Option<OnPremConfig>)
:A list of Amazon Resource Names (ARNs) of agents to use for a Network File System (NFS) location.
mount_options(NfsMountOptions)
/set_mount_options(Option<NfsMountOptions>)
:Specifies how DataSync can access a location using the NFS protocol.
- On success, responds with
UpdateLocationNfsOutput
- On failure, responds with
SdkError<UpdateLocationNfsError>
sourcepub fn update_location_object_storage(&self) -> UpdateLocationObjectStorage
pub fn update_location_object_storage(&self) -> UpdateLocationObjectStorage
Constructs a fluent builder for the UpdateLocationObjectStorage
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:Specifies the ARN of the object storage system location that you’re updating.
server_port(i32)
/set_server_port(Option<i32>)
:Specifies the port that your object storage server accepts inbound network traffic on (for example, port 443).
server_protocol(ObjectStorageServerProtocol)
/set_server_protocol(Option<ObjectStorageServerProtocol>)
:Specifies the protocol that your object storage server uses to communicate.
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:Specifies the object prefix for your object storage server. If this is a source location, DataSync only copies objects with this prefix. If this is a destination location, DataSync writes all objects with this prefix.
access_key(impl Into<String>)
/set_access_key(Option<String>)
:Specifies the access key (for example, a user name) if credentials are required to authenticate with the object storage server.
secret_key(impl Into<String>)
/set_secret_key(Option<String>)
:Specifies the secret key (for example, a password) if credentials are required to authenticate with the object storage server.
agent_arns(Vec<String>)
/set_agent_arns(Option<Vec<String>>)
:Specifies the Amazon Resource Names (ARNs) of the DataSync agents that can securely connect with your location.
server_certificate(Blob)
/set_server_certificate(Option<Blob>)
:Specifies a certificate to authenticate with an object storage system that uses a private or self-signed certificate authority (CA). You must specify a Base64-encoded
.pem
file (for example,file:///home/user/.ssh/storage_sys_certificate.pem
). The certificate can be up to 32768 bytes (before Base64 encoding).To use this parameter, configure
ServerProtocol
toHTTPS
.Updating the certificate doesn’t interfere with tasks that you have in progress.
- On success, responds with
UpdateLocationObjectStorageOutput
- On failure, responds with
SdkError<UpdateLocationObjectStorageError>
sourcepub fn update_location_smb(&self) -> UpdateLocationSmb
pub fn update_location_smb(&self) -> UpdateLocationSmb
Constructs a fluent builder for the UpdateLocationSmb
operation.
- The fluent builder is configurable:
location_arn(impl Into<String>)
/set_location_arn(Option<String>)
:The Amazon Resource Name (ARN) of the SMB location to update.
subdirectory(impl Into<String>)
/set_subdirectory(Option<String>)
:The subdirectory in the SMB file system that is used to read data from the SMB source location or write data to the SMB destination. The SMB path should be a path that’s exported by the SMB server, or a subdirectory of that path. The path should be such that it can be mounted by other SMB clients in your network.
Subdirectory
must be specified with forward slashes. For example,/path/to/folder
.To transfer all the data in the folder that you specified, DataSync must have permissions to mount the SMB share and to access all the data in that share. To ensure this, do either of the following:
-
Ensure that the user/password specified belongs to the user who can mount the share and who has the appropriate permissions for all of the files and directories that you want DataSync to access.
-
Use credentials of a member of the Backup Operators group to mount the share.
Doing either of these options enables the agent to access the data. For the agent to access directories, you must also enable all execute access.
-
user(impl Into<String>)
/set_user(Option<String>)
:The user who can mount the share has the permissions to access files and folders in the SMB share.
domain(impl Into<String>)
/set_domain(Option<String>)
:The name of the Windows domain that the SMB server belongs to.
password(impl Into<String>)
/set_password(Option<String>)
:The password of the user who can mount the share has the permissions to access files and folders in the SMB share.
agent_arns(Vec<String>)
/set_agent_arns(Option<Vec<String>>)
:The Amazon Resource Names (ARNs) of agents to use for a Simple Message Block (SMB) location.
mount_options(SmbMountOptions)
/set_mount_options(Option<SmbMountOptions>)
:Specifies how DataSync can access a location using the SMB protocol.
- On success, responds with
UpdateLocationSmbOutput
- On failure, responds with
SdkError<UpdateLocationSmbError>
sourcepub fn update_task(&self) -> UpdateTask
pub fn update_task(&self) -> UpdateTask
Constructs a fluent builder for the UpdateTask
operation.
- The fluent builder is configurable:
task_arn(impl Into<String>)
/set_task_arn(Option<String>)
:The Amazon Resource Name (ARN) of the resource name of the task to update.
options(Options)
/set_options(Option<Options>)
:Configures your DataSync task settings. These options include how DataSync handles files, objects, and their associated metadata. You also can specify how DataSync verifies data integrity, set bandwidth limits for your task, among other options.
Each task setting has a default value. Unless you need to, you don’t have to configure any of these
Options
before starting your task.excludes(Vec<FilterRule>)
/set_excludes(Option<Vec<FilterRule>>)
:Specifies a list of filter rules that exclude specific data during your transfer. For more information and examples, see Filtering data transferred by DataSync.
schedule(TaskSchedule)
/set_schedule(Option<TaskSchedule>)
:Specifies a schedule used to periodically transfer files from a source to a destination location. You can configure your task to execute hourly, daily, weekly or on specific days of the week. You control when in the day or hour you want the task to execute. The time you specify is UTC time. For more information, see Scheduling your task.
name(impl Into<String>)
/set_name(Option<String>)
:The name of the task to update.
cloud_watch_log_group_arn(impl Into<String>)
/set_cloud_watch_log_group_arn(Option<String>)
:The Amazon Resource Name (ARN) of the resource name of the Amazon CloudWatch log group.
includes(Vec<FilterRule>)
/set_includes(Option<Vec<FilterRule>>)
:Specifies a list of filter rules that include specific data during your transfer. For more information and examples, see Filtering data transferred by DataSync.
- On success, responds with
UpdateTaskOutput
- On failure, responds with
SdkError<UpdateTaskError>
sourcepub fn update_task_execution(&self) -> UpdateTaskExecution
pub fn update_task_execution(&self) -> UpdateTaskExecution
Constructs a fluent builder for the UpdateTaskExecution
operation.
- The fluent builder is configurable:
task_execution_arn(impl Into<String>)
/set_task_execution_arn(Option<String>)
:The Amazon Resource Name (ARN) of the specific task execution that is being updated.
options(Options)
/set_options(Option<Options>)
:Configures your DataSync task settings. These options include how DataSync handles files, objects, and their associated metadata. You also can specify how DataSync verifies data integrity, set bandwidth limits for your task, among other options.
Each task setting has a default value. Unless you need to, you don’t have to configure any of these
Options
before starting your task.
- On success, responds with
UpdateTaskExecutionOutput
- On failure, responds with
SdkError<UpdateTaskExecutionError>
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.