updateLocationHdfs method
- required String locationArn,
- List<
String> ? agentArns, - HdfsAuthenticationType? authenticationType,
- int? blockSize,
- CmkSecretConfig? cmkSecretConfig,
- CustomSecretConfig? customSecretConfig,
- Uint8List? kerberosKeytab,
- Uint8List? kerberosKrb5Conf,
- String? kerberosPrincipal,
- String? kmsKeyProviderUri,
- List<
HdfsNameNode> ? nameNodes, - QopConfiguration? qopConfiguration,
- int? replicationFactor,
- String? simpleUser,
- String? subdirectory,
Modifies the following configuration parameters of the Hadoop Distributed File System (HDFS) transfer location that you're using with DataSync.
For more information, see Configuring DataSync transfers with an HDFS cluster.
May throw InternalException.
May throw InvalidRequestException.
Parameter locationArn :
The Amazon Resource Name (ARN) of the source HDFS cluster location.
Parameter agentArns :
The Amazon Resource Names (ARNs) of the DataSync agents that can connect
to your HDFS cluster.
Parameter authenticationType :
The type of authentication used to determine the identity of the user.
Parameter blockSize :
The size of the data blocks to write into the HDFS cluster.
Parameter cmkSecretConfig :
Specifies configuration information for a DataSync-managed secret, such as
a KerberosKeytab or set of credentials that DataSync uses to
access a specific transfer location, and a customer-managed KMS key.
Parameter customSecretConfig :
Specifies configuration information for a customer-managed secret, such as
a KerberosKeytab or set of credentials that DataSync uses to
access a specific transfer location, and a customer-managed Identity and
Access Management (IAM) role that provides access to the secret.
Parameter kerberosKeytab :
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.
Parameter kerberosKrb5Conf :
The krb5.conf file that contains the Kerberos configuration
information. You can load the krb5.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.
Parameter kerberosPrincipal :
The Kerberos principal with access to the files and folders on the HDFS
cluster.
Parameter kmsKeyProviderUri :
The URI of the HDFS cluster's Key Management Server (KMS).
Parameter nameNodes :
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.
Parameter 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.
Parameter replicationFactor :
The number of DataNodes to replicate the data to when writing to the HDFS
cluster.
Parameter simpleUser :
The user name used to identify the client on the host operating system.
Parameter subdirectory :
A subdirectory in the HDFS cluster. This subdirectory is used to read data
from or write data to the HDFS cluster.
Implementation
Future<void> updateLocationHdfs({
required String locationArn,
List<String>? agentArns,
HdfsAuthenticationType? authenticationType,
int? blockSize,
CmkSecretConfig? cmkSecretConfig,
CustomSecretConfig? customSecretConfig,
Uint8List? kerberosKeytab,
Uint8List? kerberosKrb5Conf,
String? kerberosPrincipal,
String? kmsKeyProviderUri,
List<HdfsNameNode>? nameNodes,
QopConfiguration? qopConfiguration,
int? replicationFactor,
String? simpleUser,
String? subdirectory,
}) async {
_s.validateNumRange(
'blockSize',
blockSize,
1048576,
1073741824,
);
_s.validateNumRange(
'replicationFactor',
replicationFactor,
1,
512,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'FmrsService.UpdateLocationHdfs'
};
await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'LocationArn': locationArn,
if (agentArns != null) 'AgentArns': agentArns,
if (authenticationType != null)
'AuthenticationType': authenticationType.value,
if (blockSize != null) 'BlockSize': blockSize,
if (cmkSecretConfig != null) 'CmkSecretConfig': cmkSecretConfig,
if (customSecretConfig != null)
'CustomSecretConfig': customSecretConfig,
if (kerberosKeytab != null)
'KerberosKeytab': base64Encode(kerberosKeytab),
if (kerberosKrb5Conf != null)
'KerberosKrb5Conf': base64Encode(kerberosKrb5Conf),
if (kerberosPrincipal != null) 'KerberosPrincipal': kerberosPrincipal,
if (kmsKeyProviderUri != null) 'KmsKeyProviderUri': kmsKeyProviderUri,
if (nameNodes != null) 'NameNodes': nameNodes,
if (qopConfiguration != null) 'QopConfiguration': qopConfiguration,
if (replicationFactor != null) 'ReplicationFactor': replicationFactor,
if (simpleUser != null) 'SimpleUser': simpleUser,
if (subdirectory != null) 'Subdirectory': subdirectory,
},
);
}