You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed that when a .net web api is started using Aspire the app host lifetime signals ( IHostApplicationLifetime) are not coming through when the app host is stopped or the api is stopped using the dashboard.
In my .net web api project I have code like this in the Program.cs:
app.Lifetime.ApplicationStopping.Register(()=>{// some code});
Expected Behavior
I expect the code to be executed when the AppHost is shutdown using for example [CTRL] + [C].
I also expect the code to be executed when to Stop command is issued through the built-in Aspire dashboard.
Steps To Reproduce
No response
Exceptions (if any)
No response
.NET Version info
No response
Anything else?
No response
The text was updated successfully, but these errors were encountered:
Is there an existing issue for this?
Describe the bug
I noticed that when a .net web api is started using Aspire the app host lifetime signals ( IHostApplicationLifetime) are not coming through when the app host is stopped or the api is stopped using the dashboard.
In my
.net web api
project I have code like this in theProgram.cs
:Expected Behavior
I expect the code to be executed when the
AppHost
is shutdown using for example [CTRL] + [C].I also expect the code to be executed when to Stop command is issued through the built-in Aspire dashboard.
Steps To Reproduce
No response
Exceptions (if any)
No response
.NET Version info
No response
Anything else?
No response
The text was updated successfully, but these errors were encountered: