ashb commented on a change in pull request #6655: [AIRFLOW-6056] Allow 
EmrAddStepsOperator to accept job_flow_name as alternative to job_flow_id
URL: https://github.com/apache/airflow/pull/6655#discussion_r352485257
 
 

 ##########
 File path: airflow/contrib/operators/emr_add_steps_operator.py
 ##########
 @@ -40,18 +43,26 @@ class EmrAddStepsOperator(BaseOperator):
     @apply_defaults
     def __init__(
             self,
-            job_flow_id,
+            job_flow_id=None,
+            job_flow_name=None,
             aws_conn_id='s3_default',
             steps=None,
             *args, **kwargs):
         super().__init__(*args, **kwargs)
         steps = steps or []
-        self.job_flow_id = job_flow_id
         self.aws_conn_id = aws_conn_id
+        self.emr_hook = EmrHook(aws_conn_id=self.aws_conn_id)
 
 Review comment:
   Please don't do this -- don't make connections/requests inside `__init__`, 
it should only be done in `execute()`

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

Reply via email to