Operations | Monitoring | ITSM | DevOps | Cloud

elmah.io

Creating AWS email templates with Handlebars.js and MJML

In the next two posts (maybe more) I'll share how we have developed elmah.io's email templates currently sent out using Amazon Web Services (AWS). This first post will introduce template development using MJML and Handlebars.js. In the next post, I'll explain the process of building them on Azure DevOps and deploying them to AWS.

How to get the client IP in ASP.NET Core even behind a proxy

Part of implementing an error monitoring platform like elmah.io is dealing with the IP addresses of the clients generating errors. In this post, I'll show you parts of how we have implemented this in ASP.NET Core, to make sure that different hosting scenarios still produce the correct IP address. Let's jump right in. ASP.NET Core supports getting the client IP directly on the HttpContext object available throughout various places.

Deploy Access Restricted Azure website from DevOps Pipelines

We have a couple of internal websites hosted on Azure. Websites that require authentication and should only be accessed from our IP. This can easily be configured using Access Restrictions in Azure. But when doing so, you exclude the dynamic IP range for Microsoft-hosted Azure DevOps build agents. In this post, I'll show you how we set up deployment to the Access Restricted websites with a bit of PowerShell magic.

Creating and downloading zip files with ASP.NET Core

For a recent feature, I had to download a batch of files from an internal website written in ASP.NET Core. Zipping the files before downloading them, turned out as a great way of easily implementing multi-file download. .NET offers all of the needed features and in this post, I'll show you how to implement it. To get started, I'll create a new ASP.NET Core website: I'm picking the MVC template, but none of the zip-related code is specific to MVC.

Logging and global error handling in .NET 7 WPF applications

While developing elmah.io support for WPF, I had the chance to look into WPF for the first time in many years. I couldn't stop myself from digging down into all sorts of details about how logging has evolved in WPF since I last wrote a WPF app. In this post, I'll share some of the findings I made in this rediscovering journey.

Polling asynchronous APIs with Azure Durable Functions

I have been building a feature on elmah.io lately that picks up validation results from an external API. Before serverless was a thing, I would probably have done this using a scheduled task or Windows Service using Hangfire or similar. But after having migrated everything to serverless Azure Functions, I wanted a good solution running similarly. Azure Durable Functions turned out as the perfect companion and in this post, I'll show you a possible way to implement polling of an asynchronous API.

Best Chrome extensions for web developers

Chrome revolutionized the way to extend browsers with new features. Back in the day, extensions were annoying toolbars (remember the Ask toolbar?) and related spam-like additions. Today, I couldn't live without extensions. Here's a list of our favorite extensions used while developing elmah.io. Let's jump right into the extensions. All extensions are sorted alphabetically so make sure to go through the entire list for the best extensions for Chrome (and mostly Edge too).

How to download files from ASP.NET Core MVC

I have been implementing a couple of features lately that allow users to download files. During this process, I have visited various namespaces and possibilities with ASP.NET Core. In an attempt not to forget what I have learned and in the hope that this knowledge can be used by others, here is a blog post about downloading files from ASP.NET Core 😊 This post will use an ASP.NET Core MVC application as an example since that is what I am using.

How to get base URL in ASP.NET Core

You typically don't and shouldn't need to know where a web app is deployed. At least not from within the code of the web app itself. I keep seeing questions related to this, though. There are a range of reasons why this can still be relevant like if you want to generate and output an absolute URL in an MVC controller or Razor page. Here's a blog post about how to get the base URL in ASP.NET Core. Let's rewind a bit before we start looking into the code. All websites are deployed somewhere.