You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2020/06/17 15:58:16 UTC

[GitHub] [airflow] VijayantSoni commented on a change in pull request #9011: Changing from Resource to Client for EC2 and adding support for filters

VijayantSoni commented on a change in pull request #9011:
URL: https://github.com/apache/airflow/pull/9011#discussion_r441655005



##########
File path: airflow/providers/amazon/aws/hooks/ec2.py
##########
@@ -33,21 +33,90 @@ class EC2Hook(AwsBaseHook):
         :class:`~airflow.providers.amazon.aws.hooks.base_aws.AwsBaseHook`
     """
 
+    # Describe response
+    RESERVATIONS = 'Reservations'
+    INSTANCES = 'Instances'
+    STATE = 'State'
+    NAME = 'Name'
+    INSTANCE_ID = 'InstanceId'

Review comment:
       Agreed Ash, but wanting to understand, is this an anti-pattern in python or against airflow coding convention, because I do see similar being used within the code base.
   https://github.com/apache/airflow/blob/639972d995d848b16a3f283576efdbde28b8fdef/airflow/providers/google/cloud/hooks/dataflow.py#L93-L113
   
   




----------------------------------------------------------------
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.

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