2020-03-19
Self-Taught .NET Developer: How I Learned
Books and videos for the fundamentals, and then a lot of practice on substantial projects.
Early stage
Books
Pro C# 8
I actually read the version for C# 5, but this is the latest one I found on Amazon. It's more than 1,500 pages long. My pace was around 30 pages per evening after work, which worked out to about a chapter per night.
If I started to get sleepy, I let myself sleep. When I'm learning new things, I often get sleepy. My theory is that my brain is working extra hard and needs to rest to crystalize the new knowledge.
I knew that I would neither understand nor remember everything I read. This was simply to provide a broad overview... at least after the initial chapters on the core of the language, which I did need to learn. In the future, I expected that I would either:
- Remember that such-and-such thing existed, and look for more details to actually use the feature, or
- Be able to learn the forgotten feature more easily the second time around after priming my mind initially
I think both cases happened in actuality.
Effective C#
I learned a lot about how to write clean C#. Each "Item" is a couple pages long and covers an important lesson/guideline/rule. The chapters are the following:
- C# Language Idioms
- .NET Resource Management
- Expressing Designs in C#
- Working with the Framework
- Dynamic Programming in C#
- Miscellaneous
Some of the Items include:
- Use Properties Instead of Accessible Data Members
- Prefer Query Syntax to Loops
- Distinguish Between Value Types and Reference Types
- Limit Visibility of Your Types
- Avoid ICloneable
- and more...
I feel like it definitely provided some solid foundations at the beginning of my C# learning to keep me from developing bad habits early on.
Videos
While reading those two books, I tried to line up videos as much as possible, as well.
One of my early sources for video content was Bob Tabor's LearnVisualStudio.net (now just https://bobtabor.com/). The progression in his videos largely lined up with the progression in Pro C# 8, which helped to reinforce the learning from two angles. I also liked that his courses included simple exercises at the end of each, allowing me to punch out some basic code in Visual Studio to start getting familiar with that.
After finishing most of his content and spending a couple aimless weeks wandering around YouTube, I finally discovered the fantastically curated C# learning path at Pluralsight.
The quality of the content is excellent. The user experience is fantastic. The guided path is intelligent and covers many important topics very well. I was hooked and began spending around 1-2 hours per evening going through course after course. They track your progress with very simple metrics, which almost felt like a video game to me, which kept me even more motivated to keep going.
I've since gotten rid of my TV. If I want something to watch while eating dinner or something, I turn on a Pluralsight video and improve myself a tiny bit more. Since finishing the C# path, I've watched a number of other courses in various paths and as individual units (64 courses completed so far). I'm 100% convinced this has helped to dramatically ramp up my learning curve.
I was very nervous before starting officially as a professional developer that all of my theoretical knowledge wouldn't transfer to on-the-job skills, but it turned out that it actually set me up on a solid foundation to succeed, and I had a very successful first year as a developer.
Anyway, in order, here's what I watched from Pluralsight the first 12 months (I think the C# path has changed since then):
- C# Fundamentals with Visual Studio 2015C# Equality and ComparisonsC# Collections FundamentalsC# InterfacesDefensive Coding in C#C# Best Practices: Collections and GenericsC# Events, Delegates, and LambdasPractical LINQC# Extension MethodsObject Oriented Programming Fundamentals in C#Web API DesignMicroservices ArchitectureGetting Started with Asynchronous Programming in .NETA Comparison of Microsoft Web TechnologiesAutomated Testing for Fraidy Cats Like MeGetting Started with Entity Framework 6C# Concurrent CollectionsTest First Development - Part 1Introduction to the ASP.NET Web APIIntroduction to Identity and Access Control in .NET 4.5C# Tips and TrapsAngularJS Get StartedHTML FundamentalsAngularJS: The Big PictureIdentity and Access Control in ASP.NET 4.5Building and Securing a RESTful API for Multiple Clients in ASP.NETIntroduction to CSSAngularJS FundamentalsAngularJS Services In-DepthCSS PositioningAngularJS Routing In-DepthQuickstart to JavaScript: Volume 1Quickstart to JavaScript: Volume 3AngularJS Unit Testing In-Depth, Using ngMockAngularJS Directives FundamentalsJavaScript Design PatternsAngularJS Line of Business ApplicationsAngularJS Best PracticesTypeScript FundamentalsAngular: First LookGetting Started with Reactive Programming using RxJSTypeScript In-Depth
Beyond the Elementary Basics
Books
I don't think the list below is in any particular order. I just know that I read these - some partly, others fully - throughout my first year on the job.
Dependency Injection in .NET
During my first year, I led the development of my team's first Web API. It was a relatively new push throughout the organization, so there wasn't a ton of examples that I could leverage from other teams.
After learning about unit testing, and realizing that I had no idea how to expect my Web API code to actually behave, I wanted to unit-test everything very thoroughly. Motivated by this, I quickly realized how using dependency injection to manage dependencies throughout the application would be essential for promoting testability.
This book looked like the standard-bearer on Amazon. It turned out to be exactly what I needed. Going through it, combined with some pinpointed videos online, I was able to use good DI practices to build the API, helping me to reach my primary goal of straightforward testability.
Of course, testability isn't the only reason to use DI, and the book does a good job of covering everything else. I won't repeat it here.
The Art of Unit Testing: with examples in C#
I had come across this book on Amazon about a month before finally purchasing it. Later, I stumbled upon an hour-long video on YouTube of the author, Roy Osherov, giving a talk at a conference on unit testing. The talk was fantastic, so I had to buy the book.
As an intro to unit testing, with a good mix of philosophy and practicality, this book was an enjoyable read. It helped me to shift my mindset away from normal best practices in software development, to the slightly different best practices for writing good unit tests. Namely, repetition can be more acceptable for unit tests if it helps to make the test understandable.
It also discusses how doing TDD can improve code quality by enforcing good patterns, gives an overview of various testing and mocking frameworks, and discusses different testing paradigms like TDD, ATDD, and others.
I learned a lot, and should probably revisit it from time to time. It's a good intro and a solid resource.
Design Patterns
At the very beginning of my journey to self-taught professional programmer, I interviewed a senior PM and dev at my then-employer. They were able to give me a fantastic breakdown of the industry, providing a bunch of jargon and things to look into and keep in mind. One was TDD and the idea of a failing test. The other was the importance of design patterns.
This is the bible of design patterns, written by the Gang of Four. Unfortunately, I didn't get as far as I would have liked. Reading UML still doesn't come easy to me, and it definitely didn't at that time, either. I think I need a little more interactivity, which is why the 15+ hour course on Pluralsight covering various design patterns was much more easy for me to digest.
Nevertheless, it got me off to a good start. Thanks to those two individuals, and thanks to some early education on the subject, I think I was able to develop some good habits when evaluating a problem. I think in patterns in real life, so thinking in design patterns for software problems just feels right to me, as well.
This is definitely a book that I need to take a second look at.
Patterns of Enterprise Application Architecture
During this first year, I discovered and fell in love with Martin Fowler's work. I like the way he writes, and I like the way he thinks.
This is one of his classic books, and it has helped me to think through and analyze different architectures at a couple different employers so far. It's best when you can speak with another developer who has spent time in Fowler's world, because then you have a rich vocabulary that you can use to discuss otherwise complex topics. I think this was one of the primary aims of the book (and any design pattern endeavor).
Refactoring: Improving the Design of Existing Code
Another Fowler book, goes into detail introducing various patterns for making systematic refactorings, as well as the reasons why you should want to refactor.
I'm amazed at how the authors could judiciously categorize so many different types of refactoring actions. On top of categorization, they go another step and explain why you'd want to do one action, or why you wouldn't want to, and how it interacts with other refactoring patterns.
The intro chapters are especially insightful, because he speaks more freely about the way he thinks when looking at legacy code and/or refactoring any code, as well as how he likes to make small changes to code to continually make it more legible. All good ideas to keep in mind, and pretty cool to see a master at his craft transform a piece of mediocre code into something clean and buttoned up.
Pro ASP.NET Web API Security
This book was rated highly on Amazon, and I made it through about 5 chapters. The content looks impressive when scanning the table of contents and the chapters themselves, but there was just something about the way the author writes that never seemed to flow to me. I found myself constantly re-reading different sentences or passages multiple times to understand what he was trying to say.
The content is probably good, but the English is awkward. Maybe I'll give it another try eventually, but probably not.
Videos
Oddly, I spent a good amount of time watching videos on Angular, but no books. Also during this second year, I was working at a new company. During the interviews with them, they asked more standard computer science questions on things like algorithm efficiency (Big O Notation) and implementations of hash tables (dictionaries).
Despite successfully passing the interviews and getting hired, I felt that I was missing some core pieces of knowledge, so that was also reflected in the videos watched during this time.
Finally, near the end of my initial employer, I spent some time setting up the new API and Angular projects I'd created on our new CI/CD platform of TeamCity and Octopus. For this, I ended up using a decent amount of Powershell, so I thought I might need to get some more familiarity with it.
Here's the list:
- Angular CLI
- The Case for Powershell
- Algorithms and Data Structures: Part 1
- Play by Play: Discovering PowerShell with Mark Minasi
- An Introduction to Algorithmics
- HTML5 Fundamentals
- Angular Routing
- Algorithms and Data Structures: Part 2
- C# Tips and Traps 2
- Design Patterns Library
- Flutter: Getting Started
- Angular Fundamentals
Discovering Domain Driven Design
My second coding employer had developed an exceptionally rich and supple domain model. It was mostly a joy to work with (would be more so if you could compare against the alternative universe of what would have been without the rich model), but I never knew that the principles behind it were a "thing". I just thought that everybody that worked there was insanely smart, which they were.
At my next employer, we didn't have the luxury of a rich and supple (love that word) domain model... but there were aspirations to get there. On my team particularly, we scoped out a chunk of code that we believed could serve as a good starting point for Strangling the Monolith, allowing us to use good Domain Driven Design principles and practices to build something useful and easy to maintain.
To ramp up my knowledge for the task, I read a lot of books and watched the majority of the Pluralsight DDD path.
Unfortunately, that project has thus far been shelved at work. It's a big strategic mistake, in my opinion, but what do I know... I'm just a lowly developer with no significant business education at all............
Books
Domain-Driven Design Distilled
Fantastic intro to the topic, written by the same author of Implementing Domain-Driven Design .
I joked with colleagues at work when they complained it was 70+ pages that it's a very quick read because there are a lot of pictures... which is true. It's an easy read, lots of diagrams, and touches on the topics enough for non-developers to understand pretty much everything they need to know about DDD. For developers, it provides us a soft intro so that learning the meat comes more easily in the later stages.
Domain-Driven Design
This is the reference for the subject. It's a bit more philosophically written than its more practical Implementing Domain-Driven Design, but I preferred this one over the other two in this list. Maybe it helped that I read it last and so already had a decent grasp of the concepts, making it easier to go through this and appreciate the higher-level philosophy and principles.
It has changed the way I look at software for the better.
To practice, I've been working on a private project in my spare time at home, trying to stay as true to the principles of DDD as possible. So far, I love it. As complexity increases, so far my system is still very easy to understand and modify where needed.
He was a big proponent of the word "supple" to describe an ideal Domain Model, and I'm enjoying making refactorings along the way in my own project to continually progress toward more "suppleness".
Implementing Domain-Driven Design
I read this one after Domain-Driven Design Distilled, but before Domain Driven Design. It was pretty good, but I didn't use a number of his specific implementation patterns in my hobby project. Maybe that will come back to bite me, we'll see. I'm also lucky in that I can refer back to my previous employer's fantastic Domain Model and the patterns that they used for alternatives to those found in these books.
Others have told me they really preferred this book over the other main one. The style is a bit different, so that might be a thing. Overall, though, it felt like the overall quality was comparable between the two. If you can only read one, flip a coin and you'll probably be fine... but why not read both?
Videos
I didn't watch the videos in the advanced section, yet. I'm mostly looking forward to a more in-depth look at Event Sourcing, but that one hasn't been posted (since I've last checked).
I also skipped a course by Esposito or something. I'm sure it was decent, but I couldn't stand his voice. Nothing personal.
- Clean Architecture: Patterns, Practices, and Principles
- Domain-Driven Design Fundamentals
- Domain-Driven Design In Practice
- Refactoring from Anemic Domain Model Towards a Rich One
- Specification Pattern in C#
Connecting the Dots
The next step in my development is being able to tie the pieces all together into a cohesive software system - deployed and usable. Shipping software involves more than just writing beautiful code and committing it to the cloud somewhere. Databases need provisioned. CI/CD pipelines need setup. Authentication needs configured. Code needs deployed. Etc.
The only way to do that is to work on real projects from start to finish. Work provides some of these opportunities, but it's difficult to cover all the bases in our silo'd teams and on complex projects, most of which are likely legacy and already have a number of infrastructural pieces long established.
Also, I really don't have any direct mobile UI experience, so some of the projects in my queue are chosen specifically to get that covered.
Finally, another goal of this stage is to use implicit peer pressure to force me to lift my coding standards. With open-source projects, I'm displaying my code for all to see (and criticize). With deployable apps and open-source projects, I'm displaying my finished products for all to see (and criticize). With blogging, I'm displaying my thoughts and dreams for all to see (and criticize).
The criticism will hurt. So the threat of criticism provides additional motivation to go the extra mile, to stretch myself. And of course, the actual criticism will (hopefully) teach me new ways to do/see/think about things.
It's all a giant intense learning experience!
Projects
Super Secret App
This is my main baby, but I think it might actually have commercial value when it's finished... so I can't talk about it too much.
But it has a ton of cool technical stuff in it for me to learn, including:
- Domain Driven Design
- Message-based asynchronous architecture
- Event sourcing
- Cloud hosting
- Mobile development
- End-to-end web development
- Public API built for integrations with third-parties
- Modern Authentication
- Individual user accounts
- Field level encryption
- and more...
JsonCryption
This small project spun off from the one above. I needed to modify my JSON serializer to use with Marten so that I could easily encrypt different fields of my C# objects with a straightforward API. MongoDB has a similar feature, but it requires using MongoDB. I'm using Marten specifically because I like how they handle Event Sourcing... but Marten requires using Postgres.
I've already learned a ton from this short project, including:
- Optimizing .NET reflection with Expression trees
- Using GitHub Actions for CI/CD
- Publishing to NuGet in a CI/CD pipeline
- OWASP best practices for encryption
- Key Management Systems
- and more...
Todo Bubbles
Every developer needs to do their own todo list at some point, right? I have an idea for a slight variation on the usual todo list, making use of what I think is a key psychological trait in order to fill a specific niche.
More details will come probably later this summer. I want to finish the first project before starting this one. I'm not sure if anybody else will find it useful, but I know I could use the specific feature set that this guy will provide.
And all the while, I expect to learn:
- More mobile development
- Mobile app deployment
- Probably some fun little UI stuff
This Blog
I like to relate things to seemingly unrelated things. It helps me to understand both at a deeper level, I find. I'm not sure if anybody else will agree, or if they'll agree with the weird relationships I find with programming and business (religion, war, seduction...).
But I like writing about it, if nothing more than to store my thoughts. Also, as many people often say, forcing ourselves to write down our thoughts and ideas helps us to curate and refine them.
Writing is a skill by itself. It's useful in life to be a good writer. It's useful as a programmer to be a good writer. We all have complicated things to communicate with people we care about, about things we care about. I'm not a great writer, but I think I can improve, and I think it will improve other areas in my life - including the code I write.