get_plan
(**kwargs)¶Gets code to perform a specified mapping.
See also: AWS API Documentation
Request Syntax
response = client.get_plan(
Mapping=[
{
'SourceTable': 'string',
'SourcePath': 'string',
'SourceType': 'string',
'TargetTable': 'string',
'TargetPath': 'string',
'TargetType': 'string'
},
],
Source={
'DatabaseName': 'string',
'TableName': 'string'
},
Sinks=[
{
'DatabaseName': 'string',
'TableName': 'string'
},
],
Location={
'Jdbc': [
{
'Name': 'string',
'Value': 'string',
'Param': True|False
},
],
'S3': [
{
'Name': 'string',
'Value': 'string',
'Param': True|False
},
],
'DynamoDB': [
{
'Name': 'string',
'Value': 'string',
'Param': True|False
},
]
},
Language='PYTHON'|'SCALA',
AdditionalPlanOptionsMap={
'string': 'string'
}
)
[REQUIRED]
The list of mappings from a source table to target tables.
Defines a mapping.
The name of the source table.
The source path.
The source type.
The target table.
The target path.
The target type.
[REQUIRED]
The source table.
The database in which the table metadata resides.
The name of the table in question.
The target tables.
Specifies a table definition in the Glue Data Catalog.
The database in which the table metadata resides.
The name of the table in question.
The parameters for the mapping.
A JDBC location.
An argument or property of a node.
The name of the argument or property.
The value of the argument or property.
True if the value is used as a parameter.
An Amazon Simple Storage Service (Amazon S3) location.
An argument or property of a node.
The name of the argument or property.
The value of the argument or property.
True if the value is used as a parameter.
An Amazon DynamoDB table location.
An argument or property of a node.
The name of the argument or property.
The value of the argument or property.
True if the value is used as a parameter.
A map to hold additional optional key-value parameters.
Currently, these key-value pairs are supported:
inferSchema
— Specifies whether to set inferSchema
to true or false for the default script generated by an Glue job. For example, to set inferSchema
to true, pass the following key value pair: --additional-plan-options-map '{"inferSchema":"true"}'
dict
Response Syntax
{
'PythonScript': 'string',
'ScalaCode': 'string'
}
Response Structure
(dict) --
PythonScript (string) --
A Python script to perform the mapping.
ScalaCode (string) --
The Scala code to perform the mapping.
Exceptions
Glue.Client.exceptions.InvalidInputException
Glue.Client.exceptions.InternalServiceException
Glue.Client.exceptions.OperationTimeoutException