Please check below the list of things I've tried before closing as duplicate.
The problem:
- I create a brand new ASP.NET MVC application, I build the application and I run it --> The page takes between 20-30 seconds to load.
- Every time I rebuild the application and then try to load the page, it takes 20-30 seconds even if I do so immediately after the previous build (i.e., not an idle-timeout issue, I guess?).
I've been struggling with this problem since yesterday, I read every post/article I could found about this with no luck. Though, I have to admit that I'm new to ASP.NET and web development in general and not familiar with the IIS configuration so I might've missed something.
The things I've tried:
Disabled antivirus and firewall.
Disabled IPv6 by commenting the
::1 localhostline in the hosts file. My hosts file looks like this:127.0.0.1 localhost # ::1 localhostTried different browsers.
Changed the port of the application URL.
Changed the application URL from
localhost:portto127.0.0.1:portbut when I do so, I get:Bad Request - Invalid Hostname
Uninstalled and reinstalled IIS Express (tried multiple versions: 7.5, 8.0, and 10.0).
Tried installing the "Application Development Features" under
Internet Information Services\World Wide Web Services.Launched the VS installer and run a repair.
Environment information:
- Windows 7 x64.
- Visual Studio 2015.
- .NET 4.5.2.
- IIS currently enabled features: I'm using IIS Express so I'm not sure if this is related.
Any idea what could be causing this problem?
Update:
I just tried using Jexus Manager. Loaded the configuration from the .sln file as shown here, started the website and tried the following scenarios:
- Browsing the website after restarting it (both actions in Jexus Manager) -> 15-20 seconds.
- Browsing the website (using Jexus) after rebuilding the solution in VS --> 30+ seconds.
