Condition
- class aws_cdk.aws_glue_alpha.Condition
Bases:
object(experimental) A condition that determines when a conditional trigger fires.
A condition watches exactly one target in exactly one state: use {@link Condition.job} to watch a job or {@link Condition.crawler} to watch a crawler. Because the state is a required argument of each factory, a condition can never reference a target without its state, or both a job and a crawler.
- Stability:
experimental
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. import aws_cdk.aws_glue_alpha as glue_alpha from aws_cdk.interfaces import aws_glue as interfaces_glue # crawler_ref: interfaces_glue.ICrawlerRef condition = glue_alpha.Condition.crawler(crawler_ref, glue_alpha.CrawlerState.RUNNING, logical_operator=glue_alpha.ConditionLogicalOperator.EQUALS )
- Stability:
experimental
Static Methods
- classmethod crawler(crawler, crawl_state, *, logical_operator=None)
(experimental) Create a condition on the state of a crawler.
- Parameters:
crawler (
ICrawlerRef) – the crawler to watch.crawl_state (
CrawlerState) – the crawler state that satisfies the condition.logical_operator (
Optional[ConditionLogicalOperator]) – (experimental) The logical operator for the condition. Default: ConditionLogicalOperator.EQUALS
- Stability:
experimental
- Return type:
- classmethod job(job, state, *, logical_operator=None)
(experimental) Create a condition on the state of a job.
- Parameters:
job (
IJobRef) – the job to watch.state (
JobState) – the job state that satisfies the condition.logical_operator (
Optional[ConditionLogicalOperator]) – (experimental) The logical operator for the condition. Default: ConditionLogicalOperator.EQUALS
- Stability:
experimental
- Return type: