The importance of software design

Nicholas Ocket
7 min readOct 9, 2022

--

Software design is important. Do you know why? Because it saves time and thus it saves money. Do you know what software design is? Do you know how to design software? Don’t worry if you don’t know the answer to any of these questions. But software design is important, so let’s do something about it.

Once upon a time …

… there was this developer (which will be referred to as both he and she interchangingly btw) working on a small change request. There is a bit of pressure and a bit of a tight deadline. Her product manager said that the feature isn’t all that big, the requested changes are very easy and she should be able to do it in a couple of days. And some other developer, a senior, claimed to be able to do it in 2 days. Because according to that senior developer, there is a lot of code which can be reused.

However, our developer struggles. The codebase isn’t all that straight forward. It is kind of hard and annoying to navigate, because at times it just doesn’t seem to make sense at all. And so it took him more than half a day to figure out which code you are supposed to reuse and where it is in the code base. He did go to that senior developer to ask for a bit of help, but that person was busy with a very important bug and could not be bothered.

She is not really sure if the time she spent searching for the code to reuse is part of the time she has to finish the task. And right now, she is implementing the requested changes. But she is still struggling. There are tests, but they are grotesk and also hard to understand. Each test seems to need a huge amount of setup before it can be run. And when she tries to implement her own tests, it always seems like she forgets something small just to get the test running.

The scream when your new tests run but the existing ones do not

And there is another problem: the code that is supposed to be reused, isn’t a 100% fit. Our developer needs to make some small tweaks. Unfortunately, that doesn’t seem to be very straightforward either. He faces an awkward problem: after he has made his changes, he either gets his tests to pass or the already existing tests. But up until now, he can’t get all the tests to pass. Aaargh, what is this!? And in the back of his head, he can hear the clock ticking over the voice of his product manager who seems to keep on whispering in his mind how easy this is supposed to be.

She figures that in order to pass all of the tests, she needs to make changes to code she didn’t even know existed. That is risky, she hardly has an idea what the purpose of that code is. Luckily, there are tests to back her up. She does have to adjust the tests to the changes she made. And these tests are like all the other tests: big, hard to understand what is going on and needing a lot of setup. Eventually, after a bit more than 4 days, she manages to get her pull request approved. Only to realise that there are merge conflicts. In her quest to make all the tests pass, she has touched some code files that other developers have changed in the meantime. And it seems like they changed them a lot. She cringes at the idea of going through the pain again to figure out how to make all of those tests pass.

Does this sound familiar? It could very well be, and it sure does sound familiar to me. That is because it is not just any story, it is something I have encountered in my career. And not just once. While pair programming or mobbing might have helped, the base problem of the story is just a poorly designed codebase.

What is software design?

Software design is a process where we think about a problem that a group of people have and we come up with a solution in the form of code. The people that have this problem, you might say that they have certain needs or requirements. They require something from this solution that we are going to build. So in this process of coming up with a solution, we listen to these requirements and we try to take them into account.

Software design is also something that emerged over time, trying to fix the problems at hand. Writing software actually isn’t that new, mankind has been writing software for quite a few decades now. Sure, it looked differently, but programmers (there weren’t that many programmers back then) had the same problems as we have now:

  • Software going over budget
  • Damage caused by software
  • Poor productivity

People realised that they could do better. Over time, developers started to figure out what exactly is causing these problems. They recognised certain traits in code and started seeing patterns. Driven by the need for better software, people figured out solutions for these kinds of problems. And so best practices, guidelines and principles emerged. These best practices, guidelines and principles help in making software valuable for a longer time. They make software easier to maintain.

So software design is basically the art of saving time and money in the long run. As a starting developer, you might not realise, but developing software has a price card. It costs a lot of money. However, that is nothing compared to the cost of maintaining that software. And that is what these best practices, guidelines and principles are all about: knowing how to decompose problems, knowing how to structure code. And all of that to keep the cost of maintaining the code as low as possible.

On one hand, software design is a process where we make an effort to come up with a valuable software solution for a specific problem. On the other hand, software design is a toolbox filled with knowledge and techniques that come from people who were already coding when we were still playing make believe.

This is where the importance of software design is crystal clear. A well structured codebase, which is easy to understand and navigate, easy to test and which enables teamwork can save time and money. That is incredibly valuable! And you wouldn’t believe the amounts of time and money wasted by scenarios like the one I described.

But it is only one side of the importance of software design. What if you know how to turn problems into maintainable code? What would it mean for you if you understood the problems of the codebase and you could explain that, instead of only two days, it is going to be more. What if you understand how to improve existing code so that the maintenance cost doesn’t go up anymore? That would make you a very valuable asset for a company.

So software design is not only important for the companies you are going to work for. It is also very important for you. It is the next step to take to level up your career. So if you are serious about supercharging your career, software design should be your next move.

Starting with software design

Do you know how to design software? Do you have a strategy to break down problems into maintainable code? If not, don’t worry. It is however not something you can answer in a few paragraphs. That is something that takes some time to learn. But here are a few pointers:

  • Keep it as simple as possible. When you start out with software design, you will learn a lot of different principles and techniques. And I get it: it will feel like you have a new hammer and everything you see is a nail. While that can make for good practice to sharpen your skills, it is not actually not a good idea. Some techniques and principles can make the code more complex if complexity is not expected. And we don’t really want that. There is a design principle acronym for that: YAGNI or in other words: You Ain’t Gonna Need It.
  • To be good in software design is to understand that it is a game of trade offs. Some principles, guidelines or design patterns come with drawbacks. Knowing when to apply which guideline or principle is key.
  • Start with the core concepts of software design. These are often way easier to understand and they will help you with understanding the more difficult principles and patterns. I know it is tempting to start with the ‘pro’ stuff, because everybody is talking about them. Just know that there are a lot of people out there who can talk the talk but don’t really know how to walk the walk. You don’t start a marathon halfway. You start at the start.
  • Don’t just absorb these principles and concepts, try to own them instead. You should understand these concepts, and figure out the why. Where do these concepts come from and what are they trying to solve? This is what I mean with walking the walk. It will allow you to make better design decisions and you will be more effective in applying the variety of principles and techniques.

--

--

Nicholas Ocket

I am Nicholas, a software engineer with more than a decade of experience. My mission is to help developers to truly understand and apply software design.