-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove EMR Conn from example #525
Conversation
Codecov Report
@@ Coverage Diff @@
## main #525 +/- ##
=======================================
Coverage 98.27% 98.27%
=======================================
Files 72 72
Lines 3996 3996
=======================================
Hits 3927 3927
Misses 69 69 Continue to review full report at Codecov.
|
@@ -72,7 +71,7 @@ | |||
cluster_creator = EmrCreateJobFlowOperator( | |||
task_id="create_job_flow", | |||
job_flow_overrides=JOB_FLOW_OVERRIDES, | |||
emr_conn_id=EMR_CONN_ID, | |||
aws_conn_id=AWS_CONN_ID, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
will this fail for apache-airflow-providers-amazon < 4.1.0 ? We should make it fail safe for previous versions of the provider then. Something similar to this, with a try-except block catching the exception: #471 (comment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm, it would fail for apache-airflow-providers-amazon < 4.1.0. Does it make sense to safe fail here since this is an integration test?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would recommend to add try-except block to fail safe for previous versions as well as @pankajkoti suggested even though it is in integration
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@phanikumv @bharanidharan14 what is your opinion on this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@pankajkoti I would recommend to add try-except block. I have mentioned it already
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure if we can use try-catch for an argument being passed to the operator.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps we can add a comment in the example DAG that based on the versions of the provider what arguments are expected
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@pankajastro adding comments in the example DAG is reasonable to me, so it helps user to know what arguements needs to be passed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@pankajastro Is this review comment is addressed ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, I have added a comment.
0ae6bf3
to
aeabf65
Compare
Now
emr_conn_id
is optional in EmrCreateJobFlowOperator since the configuration we pass using paramjob_flow_overrides
so theemr_conn_id
is no longer require. We can merge this once the provider for June is releasedapache-airflow-providers-amazon==4.1.0
OSS PR: apache/airflow#24306