Reputation: 953
I'm maintaining a legacy ASP.NET MVC app (on .NET 4.8). One of my pages is unacceptably slow, often taking 30+ seconds to send a response to the browser. I've used MiniProfiler to try to find what's being slow. The results are below:
duration (ms) | with children (ms) | from start (ms) | |||
---|---|---|---|---|---|
/Administer/ManageUsers |
30530.16 | 37085.67 | +0.00 | ||
ManageUsers |
414.11 | 5553.60 | +3.93 | ||
GetUsers |
5118.44 | 5118.44 | +418.00 | ||
CreateModel |
21.05 | 21.05 | +5536.47 | ||
Render: ManageUsers |
236.36 | 1000.70 | +5558.86 | ||
Render partial: _ManageUsersFilter |
726.86 | 726.86 | +5677.21 | ||
Render partial: _LoginPartial |
13.40 | 13.40 | +6495.95 | ||
Render partial: _LoginPartial |
11.18 | 11.18 | +6520.76 | ||
Render partial: _LoginPartial |
10.52 | 10.52 | +6532.08 |
I've thoroughly covered the controller in profiler calls (e.g., using (MiniProfiler.Current.Step("GetUsers"))
). In stepping through the code with the debugger, it's clear that the controller accounts for about 20% of the total time. Where's the rest of it coming from?
According to this typical profiling result, the controller is taking about 5.5 seconds and rendering is taking about 1 second. What about the other 24 seconds, that are definitely occurring either during the controller return or after it.
Of course, there are many problems with the code I have the "pleasure" of maintaining, but what I'm trying to solve right now is what's taking those 24 extra seconds.
Upvotes: 0
Views: 27