databricks-sdk-java icon indicating copy to clipboard operation
databricks-sdk-java copied to clipboard

[ISSUE] Editing TERMINATED state compute clusters throws an error

Open q-thomaseastgate opened this issue 1 year ago • 0 comments

Description The description of the edit method of the ClustersAPI (https://github.com/databricks/databricks-sdk-java/blob/main/databricks-sdk-java/src/main/java/com/databricks/sdk/service/compute/ClustersAPI.java#L219) claims that it is able to edit TERMINATED state clusters. This works, as the cluster is indeed edited, but the edit method then tries to wait for the cluster to start running with waitGetClusterRunning, even though nothing has tried to start the cluster, and it is still in the TERMINATED state. This throws an error along the lines of: "Error encountered when editing cluster '<CLUSTER_NAME>'. Cause: failed to reach RUNNING, got TERMINATED: Termination requested by <TERMINATION_REQUEST_AUTHOR>".

Reproduction Use the edit cluster ClustersAPI method on a TERMINATED cluster.

Expected behavior The method should not throw an error when a TERMINATED cluster is edited, returning the relevant ClusterDetails instead.

Is it a regression? I haven't tried other versions

Debug Logs None

Other Information

  • Confirmed on Version: 0.23.0 Although this seems to still be present on main

Additional context None

q-thomaseastgate avatar May 09 '24 09:05 q-thomaseastgate