ferruzzi commented on a change in pull request #18645:
URL: https://github.com/apache/airflow/pull/18645#discussion_r722712868



##########
File path: airflow/providers/amazon/aws/operators/eks.py
##########
@@ -23,25 +23,41 @@
 
 from airflow import AirflowException
 from airflow.models import BaseOperator
-from airflow.providers.amazon.aws.hooks.eks import ClusterStates, EKSHook
+from airflow.providers.amazon.aws.hooks.eks import ClusterStates, EKSHook, 
FargateProfileStates
 from airflow.providers.cncf.kubernetes.operators.kubernetes_pod import 
KubernetesPodOperator
 
 CHECK_INTERVAL_SECONDS = 15
 TIMEOUT_SECONDS = 25 * 60
 DEFAULT_COMPUTE_TYPE = 'nodegroup'
 DEFAULT_CONN_ID = "aws_default"
+DEFAULT_FARGATE_PROFILE_NAME_SUFFIX = '-profile'
 DEFAULT_NAMESPACE_NAME = 'default'
 DEFAULT_NODEGROUP_NAME_SUFFIX = '-nodegroup'
 DEFAULT_POD_NAME = 'pod'
 
+ABORT_MSG = "{compute} are still active after the allocated time limit.  
Aborting."
+CAN_NOT_DELETE_MSG = "A cluster can not be deleted with attached {compute}.  
Deleting {count} {compute}."
+MISSING_ARN_MSG = "Creating an {compute} requires {requirement} to be passed 
in."
+SUCCESS_MSG = "No {compute} remain, deleting cluster."
+
+NODEGROUP_FULL_NAME = 'Amazon EKS managed node groups'
+FARGATE_FULL_NAME = 'AWS Fargate profiles'
+
 
 class EKSCreateClusterOperator(BaseOperator):
     """
     Creates an Amazon EKS Cluster control plane.
 
     Optionally, can also create the supporting compute architecture:
-    If argument 'compute' is provided with a value of 'nodegroup', will also 
attempt to create an Amazon
-    EKS Managed Nodegroup for the cluster.  See EKSCreateNodegroupOperator 
documentation for requirements.
+
+     - If argument 'compute' is provided with a value of 'nodegroup', will also
+         attempt to create an Amazon EKS Managed Nodegroup for the cluster.
+         See EKSCreateNodegroupOperator documentation for requirements.
+
+    -  If argument 'compute' is provided with a value of 'fargate', will also 
attempt to create an AWS
+         Fargate profile for the cluster.
+         See EKSCreateFargateProfileOperator documentation for requirements.

Review comment:
       Should be addressed in 
https://github.com/apache/airflow/pull/18645/commits/b577f159075d1c6b75d90c54303041b78025f122

##########
File path: airflow/providers/amazon/aws/operators/eks.py
##########
@@ -23,25 +23,41 @@
 
 from airflow import AirflowException
 from airflow.models import BaseOperator
-from airflow.providers.amazon.aws.hooks.eks import ClusterStates, EKSHook
+from airflow.providers.amazon.aws.hooks.eks import ClusterStates, EKSHook, 
FargateProfileStates
 from airflow.providers.cncf.kubernetes.operators.kubernetes_pod import 
KubernetesPodOperator
 
 CHECK_INTERVAL_SECONDS = 15
 TIMEOUT_SECONDS = 25 * 60
 DEFAULT_COMPUTE_TYPE = 'nodegroup'
 DEFAULT_CONN_ID = "aws_default"
+DEFAULT_FARGATE_PROFILE_NAME_SUFFIX = '-profile'
 DEFAULT_NAMESPACE_NAME = 'default'
 DEFAULT_NODEGROUP_NAME_SUFFIX = '-nodegroup'
 DEFAULT_POD_NAME = 'pod'
 
+ABORT_MSG = "{compute} are still active after the allocated time limit.  
Aborting."
+CAN_NOT_DELETE_MSG = "A cluster can not be deleted with attached {compute}.  
Deleting {count} {compute}."
+MISSING_ARN_MSG = "Creating an {compute} requires {requirement} to be passed 
in."
+SUCCESS_MSG = "No {compute} remain, deleting cluster."
+
+NODEGROUP_FULL_NAME = 'Amazon EKS managed node groups'
+FARGATE_FULL_NAME = 'AWS Fargate profiles'
+
 
 class EKSCreateClusterOperator(BaseOperator):
     """
     Creates an Amazon EKS Cluster control plane.
 
     Optionally, can also create the supporting compute architecture:
-    If argument 'compute' is provided with a value of 'nodegroup', will also 
attempt to create an Amazon
-    EKS Managed Nodegroup for the cluster.  See EKSCreateNodegroupOperator 
documentation for requirements.
+
+     - If argument 'compute' is provided with a value of 'nodegroup', will also
+         attempt to create an Amazon EKS Managed Nodegroup for the cluster.
+         See EKSCreateNodegroupOperator documentation for requirements.

Review comment:
       Should be addressed in 
https://github.com/apache/airflow/pull/18645/commits/b577f159075d1c6b75d90c54303041b78025f122




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@airflow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to