Reputation: 1286
How would you find the time it takes a web api to start up in asp.net mvc? I need a way to time the application from launching to successfully finish loading.
FYI I could use some javascript to determine the time beforeload and the time afterload and just calculate the difference. But I am not confident if this is the best way to do this.
Upvotes: 1
Views: 1206
Reputation: 16595
If you're attempting to measure the startup time on the server, you could attach a profiler or DateTime
stamp to Application_Start
event, then to the EndRequest
event. Application_Start
only fires when the application is starting up. Then you could log that data to a text file or database.
Upvotes: 1