airflow.providers.amazon.aws.sensors.eks

Tracking the state of Amazon EKS Clusters, Amazon EKS managed node groups, and AWS Fargate profiles.

Module Contents

Classes

EksClusterStateSensor

Check the state of an Amazon EKS Cluster until it reaches the target state or another terminal state.

EksFargateProfileStateSensor

Check the state of an AWS Fargate profile until it reaches the target state or another terminal state.

EksNodegroupStateSensor

Check the state of an EKS managed node group until it reaches the target state or another terminal state.

EKSClusterStateSensor

This sensor is deprecated.

EKSFargateProfileStateSensor

This sensor is deprecated.

EKSNodegroupStateSensor

This sensor is deprecated.

Attributes

DEFAULT_CONN_ID

CLUSTER_TERMINAL_STATES

FARGATE_TERMINAL_STATES

NODEGROUP_TERMINAL_STATES

UNEXPECTED_TERMINAL_STATE_MSG

airflow.providers.amazon.aws.sensors.eks.DEFAULT_CONN_ID = aws_default[source]
airflow.providers.amazon.aws.sensors.eks.CLUSTER_TERMINAL_STATES[source]
airflow.providers.amazon.aws.sensors.eks.FARGATE_TERMINAL_STATES[source]
airflow.providers.amazon.aws.sensors.eks.NODEGROUP_TERMINAL_STATES[source]
airflow.providers.amazon.aws.sensors.eks.UNEXPECTED_TERMINAL_STATE_MSG = Terminal state reached. Current state: {current_state}, Expected state: {target_state}[source]
class airflow.providers.amazon.aws.sensors.eks.EksClusterStateSensor(*, cluster_name, target_state=ClusterStates.ACTIVE, aws_conn_id=DEFAULT_CONN_ID, region=None, **kwargs)[source]

Bases: airflow.sensors.base.BaseSensorOperator

Check the state of an Amazon EKS Cluster until it reaches the target state or another terminal state.

See also

For more information on how to use this sensor, take a look at the guide: Wait on an Amazon EKS cluster state

Parameters
  • cluster_name (str) -- The name of the Cluster to watch. (templated)

  • target_state (airflow.providers.amazon.aws.hooks.eks.ClusterStates) -- Target state of the Cluster. (templated)

  • region (Optional[str]) -- Which AWS region the connection should use. (templated) If this is None or empty then the default boto3 behaviour is used.

  • aws_conn_id (str) -- The Airflow connection used for AWS credentials. (templated) If this is None or empty then the default boto3 behaviour is used. If running Airflow in a distributed manner and aws_conn_id is None or empty, then the default boto3 configuration would be used (and must be maintained on each worker node).

template_fields :Sequence[str] = ['cluster_name', 'target_state', 'aws_conn_id', 'region'][source]
ui_color = #ff9900[source]
ui_fgcolor = #232F3E[source]
poke(self, context)[source]

Function that the sensors defined while deriving this class should override.

class airflow.providers.amazon.aws.sensors.eks.EksFargateProfileStateSensor(*, cluster_name, fargate_profile_name, target_state=FargateProfileStates.ACTIVE, aws_conn_id=DEFAULT_CONN_ID, region=None, **kwargs)[source]

Bases: airflow.sensors.base.BaseSensorOperator

Check the state of an AWS Fargate profile until it reaches the target state or another terminal state.

See also

For more information on how to use this sensor, take a look at the guide: Wait on an AWS Fargate profile state

Parameters
  • cluster_name (str) -- The name of the Cluster which the AWS Fargate profile is attached to. (templated)

  • fargate_profile_name (str) -- The name of the Fargate profile to watch. (templated)

  • target_state (airflow.providers.amazon.aws.hooks.eks.FargateProfileStates) -- Target state of the Fargate profile. (templated)

  • region (Optional[str]) -- Which AWS region the connection should use. (templated) If this is None or empty then the default boto3 behaviour is used.

  • aws_conn_id (str) -- The Airflow connection used for AWS credentials. (templated) If this is None or empty then the default boto3 behaviour is used. If running Airflow in a distributed manner and aws_conn_id is None or empty, then the default boto3 configuration would be used (and must be maintained on each worker node).

template_fields :Sequence[str] = ['cluster_name', 'fargate_profile_name', 'target_state', 'aws_conn_id', 'region'][source]
ui_color = #ff9900[source]
ui_fgcolor = #232F3E[source]
poke(self, context)[source]

Function that the sensors defined while deriving this class should override.

class airflow.providers.amazon.aws.sensors.eks.EksNodegroupStateSensor(*, cluster_name, nodegroup_name, target_state=NodegroupStates.ACTIVE, aws_conn_id=DEFAULT_CONN_ID, region=None, **kwargs)[source]

Bases: airflow.sensors.base.BaseSensorOperator

Check the state of an EKS managed node group until it reaches the target state or another terminal state.

See also

For more information on how to use this sensor, take a look at the guide: Wait on an Amazon EKS managed node group state

Parameters
  • cluster_name (str) -- The name of the Cluster which the Nodegroup is attached to. (templated)

  • nodegroup_name (str) -- The name of the Nodegroup to watch. (templated)

  • target_state (airflow.providers.amazon.aws.hooks.eks.NodegroupStates) -- Target state of the Nodegroup. (templated)

  • region (Optional[str]) -- Which AWS region the connection should use. (templated) If this is None or empty then the default boto3 behaviour is used.

  • aws_conn_id (str) -- The Airflow connection used for AWS credentials. (templated) If this is None or empty then the default boto3 behaviour is used. If running Airflow in a distributed manner and aws_conn_id is None or empty, then the default boto3 configuration would be used (and must be maintained on each worker node).

template_fields :Sequence[str] = ['cluster_name', 'nodegroup_name', 'target_state', 'aws_conn_id', 'region'][source]
ui_color = #ff9900[source]
ui_fgcolor = #232F3E[source]
poke(self, context)[source]

Function that the sensors defined while deriving this class should override.

class airflow.providers.amazon.aws.sensors.eks.EKSClusterStateSensor(*args, **kwargs)[source]

Bases: EksClusterStateSensor

This sensor is deprecated. Please use airflow.providers.amazon.aws.sensors.eks.EksClusterStateSensor.

class airflow.providers.amazon.aws.sensors.eks.EKSFargateProfileStateSensor(*args, **kwargs)[source]

Bases: EksFargateProfileStateSensor

This sensor is deprecated. Please use airflow.providers.amazon.aws.sensors.eks.EksFargateProfileStateSensor.

class airflow.providers.amazon.aws.sensors.eks.EKSNodegroupStateSensor(*args, **kwargs)[source]

Bases: EksNodegroupStateSensor

This sensor is deprecated. Please use airflow.providers.amazon.aws.sensors.eks.EksNodegroupStateSensor.

Was this entry helpful?