Ben's Blog A place to share my thoughts

Async Programming in .NET: Part 3

Now that we’ve covered the foundations along with an introduction on how we write async code in C#, this article will focus on the best practices for async programming!

Read more

Async Programming in .NET: Part 2

Following on from part 1, in this post I will discuss in detail how to write async code in C#.

As a recap, asynchronous code essentially helps to remove performance bottlenecks and improve responsiveness of the application. It’s ideal for any scenario where your application is subject to blocking (I/O bound). Many APIs in .NET already support async programming (HttpClient, StreamWriter,StreamReader etc), but one might wonder why it’s not used everywhere (Node.js anyone?).

Read more

Async Programming in .NET: Part 1

I’ve been using the async and await keywords at work on both our .NET core API and Xamarin projects, but I started to feel guilty as I didn’t fully understand how asynchronous code works in the .NET framework. This post is mostly to help me put into my own words what async programming really is (and why I now think it’s awesome).

Read more

Roslynator and Intellicode

I have been experimenting with Resharper. It’s my first time using it (with VS Professional 2017), and have concluded that it’s quite a remarkable piece of software with an incredible number of features. Using resharper is a bit like having an opinionated buddy constantly looking at your code and providing you with useful hints, whilst automating and providing shortcuts to some of the more tedious jobs i.e. extracting code into a new method.

Read more

SOLID Principles

I have recently started reading Clean Code and I have been summarizing each chapter on this page. In chapter two, I found a number of references to SOLID principles. I was aware on some of the principles, but truthfully I never took the time to properly uncover their meaning, until now.

Read more