getTargetSelectionRules method
Converts source selection rules into their target counterparts for schema conversion operations.
Required permissions: dms:GetTargetSelectionRules. For
more information, see Actions,
resources, and condition keys for Database Migration Service.
May throw AccessDeniedFault.
May throw InvalidResourceStateFault.
May throw ResourceNotFoundFault.
Parameter migrationProjectIdentifier :
The migration project name or Amazon Resource Name (ARN).
Parameter selectionRules :
A JSON string that contains the source selection rules to convert into
their target counterparts. For the selection rule format and examples, see
Selection
rules in DMS Schema Conversion.
Usage:
-
Accepts only source selection rules, where
server-namein the object locator matches the source data provider. -
Supports only
explicitrule actions. -
Does not support
category-namein the object locator. - Up to 10 rules are allowed.
Implementation
Future<GetTargetSelectionRulesResponse> getTargetSelectionRules({
required String migrationProjectIdentifier,
required String selectionRules,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'AmazonDMSv20160101.GetTargetSelectionRules'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'MigrationProjectIdentifier': migrationProjectIdentifier,
'SelectionRules': selectionRules,
},
);
return GetTargetSelectionRulesResponse.fromJson(jsonResponse.body);
}