Using Gibraltar for Simple ASP.NET MVC Performance Monitoring

Behind door 7, we’re looking at performance monitoring and how you can easily use to Gibraltar to help track your application performance.

If your customers complain to you about your website being slow, your first question needs to be “Define slow”.  It means different things to different people and in website terms it can cover a multitude of issues: slow loading, slow response, slow in the browser, slow on the server, slow only on this page or in that feature. And even when narrowed down, how do you tell what slow actually means? To answer that you need numbers, because these give you a baseline to work from, a way of measuring what slow means and if it changes when you modify code.

Using Gibraltar to help with this is easy. Start with NuGet and add the Gibraltar Agent for PostSharp, which will also install any other required libraries. Then, find the code you need to measure and add the GTimer attribute to any methods you need to measure, or to a class if you need to measure all methods in a class. For example:

public class AccountController : Controller

Once you run your application and the session details are available in Gibraltar Analyst, you can view your measurements in the Metrics section of the session.

Here you can see that with just one additional attribute, you can track exactly how long each method takes. If you needed a narrower focus, figures within these methods, then you could manually add tracing to help with the measurements.

To find out more about automatic measurement of you applications, read up on using PostSharp with Gibraltar in our documentation where we have complete details on using PostSharp with Gibraltar. In later blog posts we’ll expand more on instrumentation and how Gibraltar can help you measure your application performance.

Related Posts

Loupe 4.5 Released with New Log Viewer for Web

Rapidly diagnose each error in any .NET application with our new Web Log Viewer and Exception root cause analysis, new in Loupe 4.5. New integration with Azure Service Bus and Azure Search enables full Loupe functionality without any Virtual Servers in Azure. Read more

Cloudflare Vulnerability Does Not Affect Us

The recently reported Cloudflare vulnerability where fragments of secure, encrypted user data could be exposed to a third party does not affect Gibraltar Software even though we use Cloudflare because we only route static content through the Cloudflare proxy for acceleration. Read more

We're out of our Last Data Center

Back in January of 2016 we decided to completely transition out of our data centers and into the cloud. On Sunday we finally shut down the last cluster of our hardware. Read more for how we did it and whether we would do it all over again if we had... Read more

Rock solid centralized .NET logging

Unlimited applications, unlimited errors, starting at $25/month