turbaszek commented on a change in pull request #10343:
URL: https://github.com/apache/airflow/pull/10343#discussion_r479622301



##########
File path: airflow/providers/google/cloud/operators/dataproc.py
##########
@@ -627,6 +681,11 @@ def execute(self, context):
             cluster = self._create_cluster(hook)
             self._handle_error_state(hook, cluster)
 
+        self.xcom_push(
+            context,
+            key="cluster_conf",
+            value={"cluster_name": self.cluster_name, "region": self.region, 
"project_id": self.project_id,},
+        )

Review comment:
       Let's move it to right after hook invocation. In this way, there will be 
cluster link no matter what is the state of the cluster. Only problem I see is 
when deleting cluster on error state but this is an edge case




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


Reply via email to