Lee-W commented on code in PR #34071:
URL: https://github.com/apache/airflow/pull/34071#discussion_r1331064257
##########
airflow/providers/databricks/hooks/databricks.py:
##########
@@ -490,6 +567,41 @@ def start_cluster(self, json: dict) -> None:
"""
self._do_api_call(START_CLUSTER_ENDPOINT, json)
+ def activate_cluster(self, json: dict, polling: int, timeout: int | None =
None) -> None:
+ """
+ Start the cluster, and wait for it to be ready.
+
+ :param json: json dictionary containing cluster specification.
+ :param polling: polling interval in seconds.
+ :param timeout: timeout in seconds.
+ """
+ cluster_id = json["cluster_id"]
+
+ api_called = False
+ time_start = time.time()
+
+ while True:
Review Comment:
If that's the case, should we consolidate them into one method? For me, I
can not understand the logic difference by reading the names `start_cluster`
and `activate_cluster`. But this's not a huge issue though.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]