diff --git a/nexus/src/internal_api/http_entrypoints.rs b/nexus/src/internal_api/http_entrypoints.rs index f8ac97072e2..853cecfa990 100644 --- a/nexus/src/internal_api/http_entrypoints.rs +++ b/nexus/src/internal_api/http_entrypoints.rs @@ -286,7 +286,9 @@ async fn cpapi_instances_put( } /// Asynchronously report the successful result of certain instance_put calls -/// (such as the potentially long-running one made during instance creation) +/// (such as the potentially long-running one made during instance creation). +/// If Nexus has already marked the instance as failed, this returns `TimedOut` +/// so the sled-agent making the request knows to terminate the instance. #[endpoint { method = PUT, path = "/instances/{instance_id}/creation-success", @@ -302,9 +304,6 @@ async fn cpapi_handle_instance_put_success( let result = Ok(instance_state.into_inner()); let opctx = crate::context::op_context_for_internal_api(&rqctx).await; let handler = async { - // TODO: if instance_handle_creation_result errors because nexus gave - // up waiting and marked the instance as failed, tell sled-agent to - // destroy the instance nexus .instance_handle_creation_result(&opctx, &path.instance_id, result) .await