AppCenter Extensions for ASP.NET Core and Application Insights

In my previous post, I wrote about an open source project called AppCenterExtensions available at Github and I recently updated this project and added a few components for ASP.NET Core that enables including AppCenter diagnostic information in Application Insights.

The NuGet package is called AppCenterExtensions.AppInsights and contains extension methods and ITelemetryInitializer implementations to be used in a ASP.NET Core web app for including AppCenter diagnostic information when logging to Application Insights

Enabling this is easy. Assuming that the project is already configured to use Application Insights, just add the AppCenterExtensions.AppInsights NuGet package mentioned above to your ASP.NET Core and call services.AddAppCenterTelemetry() in the ConfigureServices method of the Startup class

Here’s an example:

public class Startup
    public Startup(IConfiguration configuration)
        Configuration = configuration;

    public IConfiguration Configuration { get; }

    public void ConfigureServices(IServiceCollection services)
        // Configure and register services to the IoC


    public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
        // Configure app

Once this is setup, AppCenter diagnostic information should now be searchable and visible in Application Insights.

Here’s a screenshot of search results for the x-supportkey header

and here’s a screenshot of the details of a single request containing AppCenter diagnostic information logged in Application Insights

With this flow you can now correlate Crash Reports and Analytics data from AppCenter with the HTTP requests for your backend systems in Application Insights. In the systems that I have been involved with building we include the AppCenter diagnostic information from our API Gateway to all calls to our internal Microservices

New Challenges in the Cloud

I have been building mobile solutions for nearly 2 decades, I have seen things come and go, and I had loads of fun working in this space. A great part of my mobile development career involved consulting and for most of my work, I build the entire solution, including the web services and the data store and I am extremely proud of the things I have built. For the past 4 years I have been working in the Music Streaming industry. Using the tools from Xamarin, we built software for Android and iOS with a very large shared code base. The entire organization shares components through different platforms, it was great. Our products have a very high number of daily active users and has great ratings on the Apple AppStore and Google Play.

During these 4 years, a lot of things has happened. Microsoft acquired HockeyApp then later on Xamarin a few years back, and unfortunately, things went down hill. This is of course almost to be expected as Microsoft has bigger plans for these products and they will be all well integrated into a larger suite of products. I think things are starting to look better now, but for a very long while, it has been much worse. For instrumentation we had to switch from Xamarin Insights to RayGun. At that time when we did the switch, RayGun didn’t have the same feature set as Xamarin Insights so it felt like a down grade, with a higher price tag. RayGun eventually caught up and also improved the pricing plan.

Like anything else, if you work on the same suite of products for 4 years, no matter how fun it is, it becomes less and less exciting. Lately I have taken a keen interest in the recent developments in the Microsoft Azure space and early this year a very interesting opportunity presented itself. So after weeks of consideration, I decided to take a break from full time mobile development. For the past 2 months I have been a full time Cloud developer. Although I still do side projects and most of them will most likely still be mobile, I will be working on Cloud based solutions in my day job.

Scroll to top