Mainframe Blog

“Make It Just One Bolt!” The Case for Greater Simplicity in Mainframe Code

Make It Just One Bolt
3 minute read
Mark Schettenhelm

Back in 1927, the Ford Motor Company introduced the Model A to replace the legendary Model T which had been in production for close to 20 years with few changes in design. This was a chance for Ford to start over and design a much more modern car. But in doing so, it didn’t ignore the simplicity which made the Model T such a success.

As an example, the original design for the carburetor on the new engine had 14 little screws. That was judged to be too complex, not only for assembly but for future maintenance and repair. When Zenith, the company contracted to design and manufacture the new carburetor, was told to redesign it for simplicity, it came back with a version that only had two bolts holding the carburetor together. According to a well-known story, when presented with the new design Henry Ford said, “Two is too many—make it just one bolt!” In the end, millions of Ford Model As were produced with carburetors using only one bolt. Many are still running today.

That simplicity helped in manufacturing then, and for maintenance thereafter. When I look at software development, I’m sometimes reminded of this example. As I tell developers, “Simple is hard, but most often worth it.” How often do we code 100 lines when ten will do? Why does this matter? For the same reasons it did with the Model A: It’s simpler to manufacture and simpler to maintain.

Here are five ways to keep code simple:

  • Requirements—Start with what is necessary to serve the user and solve that problem. It can be tempting to do more while you are there; to solve multiple problems by building in logic for a possible future expansion or to offer multiple options for that solution. Granted, you do need to plan for the future, but you only need to solve the one problem today.
  • Structure—I asked developer Zyad Alyashae about writing simpler code. His response? “My answer to simple code is comprised of one word— If the structure is right, the code falls right into place. The same way the one bolt would fit in place if the carburetor was created so that one bolt is good enough.” Structure your code so that the simpler solution is sufficient to address the problem at hand.

Alyashae continues, “As an example, be sure to compartmentalize. That means breaking the code into simple blocks or compartments which are assembled to build the logic. Each block should be easy to understand on its own; the function is clear. I think of it like a shape-sorter toy for kids—the existing code [or]system infrastructure is the box and the new code being added is like the shapes. If the structure is set up correctly, then the shapes fit just in place with where they belong, almost conceptually like the toy.” Avoid making code too long and too complex. You may think it’s easier that way, and it may be when you are writing it, but it won’t be over the long-term.

  • Graphical analysis—View your code with a graphical analysis tool like BMC AMI DevX Code Insights. With this tool, you can clearly see how your code flows, giving you great insight into potentially tangled logic. If it appears the logic looks like spaghetti in the chart, can you imagine how hard it is to follow the code without the graphical aid?
  • Documentation—If you feel the need to write extensive documentation for your logic, let that be a warning sign. Simple code is easier to understand and needs less documentation. The goal should be to require as little documentation as possible for a good understanding.
  • Code review—In code reviews, always ask, “Is this the simplest way? How difficult will this be to maintain?” Knowing that you could be the next person to work on this code, how do you feel about it?

I’ll say it again—Simple is hard. Developers need to take steps to deliver simplicity if we want to deliver code that can be easily maintained in the future.

Access the 2023 Mainframe Report

The results of the 18th annual BMC Mainframe Survey are in, and the state of the mainframe remains strong. Overall perception of the mainframe is positive, as is the outlook for future growth on the platform, with workloads growing and investment in new technologies and processes increasing.


These postings are my own and do not necessarily represent BMC's position, strategies, or opinion.

See an error or have a suggestion? Please let us know by emailing blogs@bmc.com.

BMC Brings the A-Game

BMC works with 86% of the Forbes Global 50 and customers and partners around the world to create their future. With our history of innovation, industry-leading automation, operations, and service management solutions, combined with unmatched flexibility, we help organizations free up time and space to become an Autonomous Digital Enterprise that conquers the opportunities ahead.
Learn more about BMC ›

About the author

Mark Schettenhelm

Mark is a DevOps Evangelist and Lead Product Manager at BMC who has experience working with developers around the world in Source Control Management, Testing, DevOps and Application Portfolio Analysis. He is a frequent conference speaker, webinar presenter, blogger, and columnist, often explaining the benefits of bringing Agile and DevOps to mainframe development and encouraging development teams to adopt new methodologies and continuously improve.

His writing has appeared in Enterprise Executive and Enterprise Tech Journal and he is a frequent contributor to DZone.com and SHARE Tech Watch. Mark is currently the Lead Product Manager for BMC products in Source Control Management, Deploy, Code and Fault Analysis.