How to improve my workflow? VS2019 with Blazor Server app and Core WebAPI project lose connection many many times

wavemaster 311 Reputation points

One project is a NET5 Web API with EF Core, the other is a Blazor Server app.

My workflow is as follows:

  1. CTRL F5 to start the Web API in the browser, Swagger UI comes up
  2. F5 on the Blazor Server app to start the debugger

More than half of the time the developer tools in the browser report "connection actively refused"

Then I stop the debugger and close the browser tabs, and repeat step 1 and 2, which mostly works now.

However, when I make changes in the Blazor app the process start again with 1.

Then several times per day I need to close VS2019 in the hope of fixing this and hearing the fans on the computer kick in.

At one time today VS 2019 was consuming 100% processor resources in Task Manager.

VS is currently on 16.8.6, and it did the same thing on version 16.8.5

What am I doing wrong here?

A set of technologies in the .NET Framework for building web applications and XML web services.
4,306 questions
A free and open-source web framework that enables developers to create web apps using C# and HTML being developed by Microsoft.
1,458 questions
Visual Studio Debugging
Visual Studio Debugging
Visual Studio: A family of Microsoft suites of integrated development tools for building applications for Windows, the web and mobile devices.Debugging: The act or process of detecting, locating, and correcting logical or syntactical errors in a program or malfunctions in hardware. In hardware contexts, the term troubleshoot is the term more frequently used, especially if the problem is major.
961 questions
{count} votes

3 answers

Sort by: Most helpful
  1. wavemaster 311 Reputation points

    @Michael Wang-MSFT

    Hmmm...... the thing is when I stopped the debugger and close the browser tabs, and redo everything again then it works.

    Wouldn't the code problem not be the same over two different debugging sessions?

    0 comments No comments

  2. Duane Arnold 3,216 Reputation points
    0 comments No comments

  3. wavemaster 311 Reputation points

    @Duane Arnold

    I had previously learned not to use starting both projects by VS because it was unreliable. Maybe maybe less unreliable than what I am doing now.


    0 comments No comments