Getting sporadic "context deadline exceeded" or "Catastrophic failure" in Aspire GA with Azure Function Isolated Worker (.Net 8)
- Dominant language
- C#
- Stars
- 6.3k
- Forks
- 991
- Avg merge
- 2d 15h
- Merged PRs (30d)
- 196
Description
I am getting occasional "context deadline exceeded" when running for Azure Function Isolated Worker (.Net 8). After a few attempts the error goes away and then it comes back with "Catastrophic failure" next time. It's very sporadic. I have had attempts when everything ran just fine.
```
info: Aspire.Hosting.DistributedApplication[0]
Aspire version: 8.0.0+d215c528c07c7919c3ac30b35d92f4e51a60523b
info: Aspire.Hosting.DistributedApplication[0]
Distributed application starting.
info: Aspire.Hosting.DistributedApplication[0]
Application host directory is: C:\Code\SCA\Func-Can-Batch\func-cancheck-batch.AppHost
info: Aspire.Hosting.DistributedApplication[0]
Now listening on: https://localhost:17187
info: Aspire.Hosting.DistributedApplication[0]
Login to the dashboard at https://localhost:17187/login?t=fd9aa5a8c33706d2adab521779a9631f
info: Aspire.Hosting.DistributedApplication[0]
Distributed application started. Press Ctrl+C to shut down.
fail: Aspire.Hosting.Dcp.dcpctrl.ExecutableReconciler[0]
run session could not be started: request round-trip failed {"Executable": {"name":"recall-fv7qgho"}, "Reconciliation": 5, "error": "Put \"https://localhost:19192/run_session?api-version=2024-03-03\": context deadline exceeded"}
```
and in other attempts run the application I get this error
```
fail: Aspire.Hosting.Dcp.dcpctrl.ExecutableReconciler[0]
run session could not be started: IDE returned a response indicating failure {"Executable": {"name":"invitation-71jjuc8"}, "Reconciliation": 12, "Status": "500 Internal Server Error", "Body": "Catastrophic failure (Exception from HRESULT: 0x8000FFFF (E_UNEXPECTED))"}
```
The state in the dashboard for the projects that time out is simply "Failed to start".
Using aspire GA
This may be related to https://github.com/dotnet/aspire/issues/3435 or https://github.com/dotnet/aspire/issues/4117
Output from dotnet --info:
```
.NET SDK:
Version: 8.0.302
Commit: ef14e02af8
Workload version: 8.0.300-manifests.3d4bb602
MSBuild version: 17.10.4+10fbfbf2e
Runtime Environment:
OS Name: Windows
OS Version: 10.0.19045
OS Platform: Windows
RID: win-x64
Base Path: C:\Program Files\dotnet\sdk\8.0.302\
.NET workloads installed:
[aspire]
Installation Source: SDK 8.0.300, VS 17.10.35013.160
Manifest Version: 8.0.2/8.0.100
Manifest Path: C:\Program Files\dotnet\sdk-manifests\8.0.100\microsoft.net.sdk.aspire\8.0.2\WorkloadManifest.json
Install Type: FileBased
Host:
Version: 8.0.6
Architecture: x64
Commit: 3b8b000a0e
.NET SDKs installed:
6.0.131 [C:\Program Files\dotnet\sdk]
6.0.321 [C:\Program Files\dotnet\sdk]
7.0.203 [C:\Program Files\dotnet\sdk]
8.0.302 [C:\Program Files\dotnet\sdk]
.NET runtimes installed:
Microsoft.AspNetCore.App 6.0.26 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 6.0.31 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 7.0.5 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 7.0.20 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 8.0.6 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 3.1.32 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 6.0.26 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 6.0.31 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 7.0.5 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 7.0.20 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 8.0.6 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 3.1.32 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 6.0.26 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 6.0.31 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 7.0.5 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 7.0.20 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 8.0.6 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Other architectures found:
x86 [C:\Program Files (x86)\dotnet]
registered at [HKLM\SOFTWARE\dotnet\Setup\InstalledVersions\x86\InstallLocation]
Environment variables:
Not set
global.json file:
Not found
```
Contributor guide
Assessment
This issue has not been assessed yet.