Recover deferred environments after provisioning failure (#42388)

## What changed

- Allow a valid Ready report to replace a deferred environment's provisioning failure while preserving the same environment instance.
- Treat provisioning failures as retryable and reconnect when a completed or concurrently publishing startup attempt contains a stale failure.
- Report provisioning failures from `status()` without starting a connection, and retain Ready state when a late failure arrives.

## Testing

- Cover recovery after failed and invalid provisioning reports, capability-root resolution after recovery, and the race between Ready and publication of an earlier startup failure.

GitOrigin-RevId: cce419403248168da81bc5a6ab20f919aed81142
This commit is contained in:
Anton Panasenko authored and copyberry committed 2026-09-02 23:49:29 +00:00
1 parent 2b554fd3f9
commit e6249b5296
9 files changed
+243 -67

No files matched your search

+1 -3
View File
@@ -187,9 +187,7 @@ impl ExecServerClient {
.to_string(),
)
})?;
provisioning_result.map_err(|message| {
ExecServerError::Disconnected(format!("environment unavailable: {message}"))
})?;
provisioning_result.map_err(ExecServerError::ProvisioningFailed)?;
}
let (websocket_url, connect_timeout, initialize_timeout) = match transport_params {