CfnJobPropsMixin
- class aws_cdk.mixins_preview.aws_glue.mixins.CfnJobPropsMixin(props, *, strategy=None)
Bases:
MixinThe
AWS::Glue::Jobresource specifies an AWS Glue job in the data catalog.For more information, see Adding Jobs in AWS Glue and Job Structure in the AWS Glue Developer Guide.
- See:
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-glue-job.html
- CloudformationResource:
AWS::Glue::Job
- Mixin:
true
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview import mixins from aws_cdk.mixins_preview.aws_glue import mixins as glue_mixins # default_arguments: Any # non_overridable_arguments: Any # tags: Any cfn_job_props_mixin = glue_mixins.CfnJobPropsMixin(glue_mixins.CfnJobMixinProps( allocated_capacity=123, command=glue_mixins.CfnJobPropsMixin.JobCommandProperty( name="name", python_version="pythonVersion", runtime="runtime", script_location="scriptLocation" ), connections=glue_mixins.CfnJobPropsMixin.ConnectionsListProperty( connections=["connections"] ), default_arguments=default_arguments, description="description", execution_class="executionClass", execution_property=glue_mixins.CfnJobPropsMixin.ExecutionPropertyProperty( max_concurrent_runs=123 ), glue_version="glueVersion", job_mode="jobMode", job_run_queuing_enabled=False, log_uri="logUri", maintenance_window="maintenanceWindow", max_capacity=123, max_retries=123, name="name", non_overridable_arguments=non_overridable_arguments, notification_property=glue_mixins.CfnJobPropsMixin.NotificationPropertyProperty( notify_delay_after=123 ), number_of_workers=123, role="role", security_configuration="securityConfiguration", tags=tags, timeout=123, worker_type="workerType" ), strategy=mixins.PropertyMergeStrategy.OVERRIDE )
Create a mixin to apply properties to
AWS::Glue::Job.- Parameters:
props (
Union[CfnJobMixinProps,Dict[str,Any]]) – L1 properties to apply.strategy (
Optional[PropertyMergeStrategy]) – (experimental) Strategy for merging nested properties. Default: - PropertyMergeStrategy.MERGE
Methods
- apply_to(construct)
Apply the mixin properties to the construct.
- Parameters:
construct (
IConstruct)- Return type:
- supports(construct)
Check if this mixin supports the given construct.
- Parameters:
construct (
IConstruct)- Return type:
bool
Attributes
- CFN_PROPERTY_KEYS = ['allocatedCapacity', 'command', 'connections', 'defaultArguments', 'description', 'executionClass', 'executionProperty', 'glueVersion', 'jobMode', 'jobRunQueuingEnabled', 'logUri', 'maintenanceWindow', 'maxCapacity', 'maxRetries', 'name', 'nonOverridableArguments', 'notificationProperty', 'numberOfWorkers', 'role', 'securityConfiguration', 'tags', 'timeout', 'workerType']
Static Methods
- classmethod is_mixin(x)
(experimental) Checks if
xis a Mixin.- Parameters:
x (
Any) – Any object.- Return type:
bool- Returns:
true if
xis an object created from a class which extendsMixin.- Stability:
experimental
ConnectionsListProperty
- class CfnJobPropsMixin.ConnectionsListProperty(*, connections=None)
Bases:
objectSpecifies the connections used by a job.
- Parameters:
connections (
Optional[Sequence[str]]) – A list of connections used by the job.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_glue import mixins as glue_mixins connections_list_property = glue_mixins.CfnJobPropsMixin.ConnectionsListProperty( connections=["connections"] )
Attributes
- connections
A list of connections used by the job.
ExecutionPropertyProperty
- class CfnJobPropsMixin.ExecutionPropertyProperty(*, max_concurrent_runs=None)
Bases:
objectAn execution property of a job.
- Parameters:
max_concurrent_runs (
Union[int,float,None]) – The maximum number of concurrent runs allowed for the job. The default is 1. An error is returned when this threshold is reached. The maximum value you can specify is controlled by a service limit.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_glue import mixins as glue_mixins execution_property_property = glue_mixins.CfnJobPropsMixin.ExecutionPropertyProperty( max_concurrent_runs=123 )
Attributes
- max_concurrent_runs
The maximum number of concurrent runs allowed for the job.
The default is 1. An error is returned when this threshold is reached. The maximum value you can specify is controlled by a service limit.
JobCommandProperty
- class CfnJobPropsMixin.JobCommandProperty(*, name=None, python_version=None, runtime=None, script_location=None)
Bases:
objectSpecifies code executed when a job is run.
- Parameters:
name (
Optional[str]) – The name of the job command. For an Apache Spark ETL job, this must beglueetl. For a Python shell job, it must bepythonshell. For an Apache Spark streaming ETL job, this must begluestreaming. For a Ray job, this must beglueray.python_version (
Optional[str]) – The Python version being used to execute a Python shell job. Allowed values are 3 or 3.9. Version 2 is deprecated.runtime (
Optional[str]) – In Ray jobs, Runtime is used to specify the versions of Ray, Python and additional libraries available in your environment. This field is not used in other job types. For supported runtime environment values, see Working with Ray jobs in the AWS Glue Developer Guide.script_location (
Optional[str]) – Specifies the Amazon Simple Storage Service (Amazon S3) path to a script that executes a job (required).
- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_glue import mixins as glue_mixins job_command_property = glue_mixins.CfnJobPropsMixin.JobCommandProperty( name="name", python_version="pythonVersion", runtime="runtime", script_location="scriptLocation" )
Attributes
- name
The name of the job command.
For an Apache Spark ETL job, this must be
glueetl. For a Python shell job, it must bepythonshell. For an Apache Spark streaming ETL job, this must begluestreaming. For a Ray job, this must beglueray.
- python_version
The Python version being used to execute a Python shell job.
Allowed values are 3 or 3.9. Version 2 is deprecated.
- runtime
In Ray jobs, Runtime is used to specify the versions of Ray, Python and additional libraries available in your environment.
This field is not used in other job types. For supported runtime environment values, see Working with Ray jobs in the AWS Glue Developer Guide.
- script_location
Specifies the Amazon Simple Storage Service (Amazon S3) path to a script that executes a job (required).
NotificationPropertyProperty
- class CfnJobPropsMixin.NotificationPropertyProperty(*, notify_delay_after=None)
Bases:
objectSpecifies configuration properties of a notification.
- Parameters:
notify_delay_after (
Union[int,float,None]) – After a job run starts, the number of minutes to wait before sending a job run delay notification.- See:
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk.mixins_preview.aws_glue import mixins as glue_mixins notification_property_property = glue_mixins.CfnJobPropsMixin.NotificationPropertyProperty( notify_delay_after=123 )
Attributes
- notify_delay_after
After a job run starts, the number of minutes to wait before sending a job run delay notification.