Steel Threads are a powerful but obscure software design approach. Learning about Steel Threads will make you a better engineer. You can use them to avoid common problems like integration pain. And you can use them to cut through the complexity of system design.
How unknown are Steel Threads? The concept was deleted from Wikipedia in 2013 because “the idea is not notable within software engineering, and hasn’t received significant coverage from notable sources.” Let’s add to the coverage, and also talk through why it is such a useful approach.
A steel thread is a very thin slice of functionality that threads through a software system. They are called a “thread” because they weave through the various parts of the software system and implement an important use case.
They are called “steel” because the thread becomes a solid foundation for later improvements.
With a Steel Thread approach, you build the thinnest possible version that crosses the boundaries of the system and covers an important use case.
Let’s say you’re building a new service to replace a part of your monolithic codebase. The most common way to do this would be
Sounds reasonable, right? Well, this is the most common way software engineers operate, but this approach has a lot of landmines.
What problems would I expect in this project?
Both of these things are avoidable, by not having a huge cutover. Note that even cutting over one percent of traffic to the new service with a feature flag is a cutover approach. Why? You’re cutting over all that one percent of traffic to all the changes at the same time.
I still would not expect it to go well. You are taking steps that are too large.
Contrast that approach with the Steel Thread way of doing it.
Isn’t this also the “strangler” pattern? Yes, but this can be used for new projects too. Read on for a greenfield example.
Integration pain is one of the bigger causes of last-minute problems in projects. When you cut over to a new system, you always find problems you don’t expect. You should be suspicious of anything that involves a cut-over. Do things in small increments.
Steel Threads integrate from the beginning, so you never have a lot of integration pain to wade through. Instead, you have small integration pain, all along the way.
Also, your service never needs to be tested before it goes live, because you’ve tested it incrementally, along the way. You know it can handle production loads. You’ve already added network latency, so you know the implications of that.
All the surprises are moved forward, and handled incrementally, as just part of the way you gradually roll out the service.
The important thing is that you have a working, integrated system, and as you work on it, you keep it working. And you flesh it out over time.
When you’re designing a system, you have a LOT of complexity. Building a set of requirements for the new system can be a challenging endeavor.
When using a Steel Thread approach, you choose some of the core requirements and phrase them in a way that cuts through the layers of the system, and exercises your design. It provides a sort of skeletal structure for the whole system.
The implementation of that Steel Thread then becomes the bones upon which further requirements can be built.
Thus, Steel Threads are a subset of the requirements of a system.
Let’s say you’re implementing a clone of Slack. Your initial Steel Thread might be something like:
“Any unauthenticated person can post a message in a hardcoded #general room in a hardcoded account. Messages persist through page refreshes.”
Note how limited this initial Steel Thread is. It doesn’t handle authentication, users, or accounts. It does handle writing messages, and persisting them.
Your second Steel Thread can move the system towards being more useful. You could, for example, have a Steel Thread that allows the message poster to choose the name they post under.
This second Steel Thread hasn’t actually done much. You still don’t have authentication, accounts, or even a concept of a user. But you have made a chat room that works enough that you can start using it.
Also, note that you haven’t pulled the Steel Thread through every portion of the system. But you have stubbed out the concepts of users and accounts.
Note that in this Slack clone example, you can get early feedback on the system you’re building, even though you haven’t built that much yet. This is another powerful reason for using Steel Threads.
After just those two Steel Threads, your team could start using the chat room full-time. Think about how much your team will learn from using your system. It’s a working system.
Compare that to what you would have learned building out the User and Account systems, hooking everything up, and finally building out a chat room.
Steel Threads are often a good place to start when designing your projects. They create a skeleton for the rest of the work to come. They nail down the core parts of the system so that there are natural places to flesh out.
I encourage you to try a Steel Threaded approach. I think you’ll find it can transform your projects. Let me know your experiences with it!
You may have heard of the term “vertical slicing”. I describe the concept in my post on Milestones.
Steel Threads are a software design technique that results in delivering your software in vertical slices. The term tends to be used to describe the initial vertical slices of a system.
They’re closely related concepts, but not completely the same.
I’ve also heard of Steel Threads being referred to as “tracer bullets”.
This article was originally published by Jade Rubick on Hackernoon.
As digital transformation accelerates, ensuring accessibility remains crucial for millions of Indians with disabilities. Addressing…
I think OpenAI is not being honest about the diminishing returns of scaling AI with…
S8UL Esports, the Indian esports and gaming content organisation, won the ‘Mobile Organisation of the…
The Tech Panda takes a look at recent funding events in the tech ecosystem, seeking…
Colgate-Palmolive (India) Limited, the oral care brand, launched its Oral Health Movement. The AI-enabled initiative…
This fast-paced business world belongs to the forward thinking organisations that prioritise innovation and fully…