Latest Articles


Secure Shell Protocol (SSH) keys provide an alternate way to authenticate with many services like GitHub. Creating them on Windows is simple using Windows Subsystem for Linux (WSL). Windows Subsystem for Linux First you'll need to have WSL running on your computer. Set up WSL for Windows. Generate SSH RSA Key Pair Open a WSL terminal (Start -> WSL -> Enter) and enter the following command: It will…

Keep Reading →


Guard Clauses provide an elegant way to ensure code inputs are valid, typically by throwing exceptions. Validation provides a solution to a similar problem, typically without the use of exceptions. When does it make sense to use each of these techniques? This article is a response to a question I received from one of my tips newsletter subscribers, Chad Boettcher. He asked: I just have a quick…

Keep Reading →


Raise your hand if you've stored entity values in a database as DateTime. Ok, everybody has their hand up. You can put your hand down - you look silly doing that while reading an article on some website. Using DateTime for entity properties and database fields is ubiquitous, but if you really care about the time portion of the value, it's often ambiguous. What time zone is the date in? Is it…

Keep Reading →


Value Objects are a key part of Domain-Driven Design and domain models created by this process. However, they're not used nearly as often by teams as they should be, and they're frequently misunderstood even by experienced dev teams. When teaching teams how to better understand Value Objects and incorporate them more in their domain models, I've found the .NET type to be a useful example. First…

Keep Reading →


Time for a recap of stats and important (and not so important) milestones from 2021, the SECOND year of the COVID-19 pandemic (yeah we thought 2020 would be THE year of the pandemic. Turns out... not so much.). Here are some other year-in-review recaps for reference and a checklist for writing your own: My 2017 Year in Review My 2018 Year in Review My 2019 Year in Review My Year in Review Post…

Keep Reading →


Software developers deal with abstractions every day. But just what is an abstraction? There are differing definitions that can sometimes cause confusion. Let's consider a few of them. Definitions Oxford (via Google as the default/top definition) defines abstraction: ab·strac·tion /abˈstrakSH(ə)n/ noun the quality of dealing with ideas rather than events. "topics will vary in degrees of…

Keep Reading →


When practicing software architecture and design, one important consideration is how the rules of the system are modeled. Are the rules ad hoc and a matter of tribal knowledge of the developers who came before, or are they explicit in the way the system and its classes are designed and used? Whenever possible, favor making the implicit explicit in your design, so that as developers come and go…

Keep Reading →


In late 2021, I presented a 30-minute session at dotNetConf on the topic of Clean Architecture with ASP.NET Core 6. At the time of writing this 2 weeks later, the video has 82k views, making it the most-watched YouTube video of the conference (not necessarily during the live event). You can check it out here if you're interested: In this article, I want to go into a bit more depth on the topic of…

Keep Reading →


It's typical for API endpoints to call application or domain services. In the case of success, the API can simply return Ok and the result of the service call. But for non-success cases, should you use exceptions to communicate from the service to the endpoint, so that it can return an appropriate status code and response? Assuming you read the title of this article, you probably already know the…

Keep Reading →


Recording a short screencast video can be a very effective way to provide a demo to stakeholders or show how a bug can be reproduced. Follow this checklist to make sure you don't miss something important. In a previous article, I wrote about how to make better, faster demos using screencast videos. Once you've got that all sorted out and have chosen the technology you want to use to record and…

Keep Reading →


Ardalis

Copyright © 2021