Learn what the difference is and when to use which

Shared code can be in a library or in a service. Image by Martin Thoma.

Preventing code duplication is a software development principle called DRYDon’t Repeat Yourself. DRY is important because duplicated code usually means way more code that needs to be maintained. If you need to fix a bug, you need to fix it in all duplicated places. If you need to extend the capabilities, you need to do it in multiple parts of the code. When a new developer adjusts one part of the duplicated code and forgets to adjust the other places, the situation gets more complicated.

There are two very different ways to keep your code DRY: Put the…


They are too expensive. The numbers speak a clear language.

Image by Dylan Calluy (left) and Axel Antas-Bergkvist (right), created by Martin Thoma

The car market is changing. While we were improving cars powered by Gasoline and Diesel for a long time, Tesla made the industry move. Electric vehicles (EV) and hydrogen cars were seen as two equally valid options for a long time, this changed in the past few years. Let me explain why I think that the hydrogen car will die.

Infrastructure Cost: Charging Stations


Photo by Lukenn Sabellano on Unsplash

Most websites only have one piece of evidence that is used to authenticate you: A password. However, having multiple pieces of evidence increases security quite a bit. Those pieces of evidence are also called “factors” and they fall into three groups:

  • Something you know: A password
  • Something you have: A password token or a device like a smartphone
  • Something you are: Biometrics

Using multiple factors for authentication is also called multi-factor authentication (MFA). If you use two factors, it is two-factor authentication (2FA). Hence 2FA is the simplest form of MFA.

After reading this article you will understand how MFA…


Coins, Utility and Security tokens, Stablecoins and NFTs: Bringing order to an ecosystem

Categorization of the top 30 cryptocurrencies + some chosen ones. Image by Martin Thoma

The crypto ecosystem grew rapidly in the past years — so rapid, that it’s hard for outsiders to even understand the various use-cases in that space. After reading this article, you should have some mental models to compare the latest blockchain projects. Let’s go!

Coins vs Tokens: A technical distinction

Coins are assets on their native blockchain, whereas tokens are assets foreign to the blockchain they live on. Examples for coins are Bitcoin on the Bitcoin blockchain and Ether on the Ethereum blockchain. Examples for tokens are Tether as a second-layer token on multiple blockchains; Uniswaps “UNI” token and Chainlinks “LINK” token use the Ethereum blockchain…


Learn what they are and how they are used

Image by Pixabay

We use signatures to show that we have read a contract and want to do our part of fulfilling it. They serve two purposes: Expressing an intend and being able to prove to the authorities that this intend was expressed in case one of the parties does not follow the contract. For example, if you sign a rental agreement, your landlord has proof that you wanted to pay the stated rent each month. And you have the proof that you actually can use the apartment.

Let’s learn about the problems of this approach and the digital equivalent!

Why handwritten signatures are problematic

Let’s first explore…


An elegant solution to change management

Bitcoin
Bitcoin
Photo by Dmitry Demidko on Unsplash.

The world is changing and developers are not perfect. The first iteration of any software always has some flaws or shortcomings that need to be adjusted after a while. For those two reasons, it is important to have a mechanism for change management. In the case of APIs of central services, you typically have an API version and a deprecation schedule.

But what do you do in a distributed system? How do you keep the system flexible and secure?

Bitcoin has an elegant solution to this problem: Bitcoin Script! After reading this article, you will understand it. Let’s go!

Anatomy of a Bitcoin Transaction

New…


They are coupled, but not the same

Images from @marjanblan (source) and Serge Kutuzov (source)

Web services change all the time. When a web service is about the be updated, you might have an approval process and a quality assurance process around that topic. You might need a manager signing off that the current release candidate (RC) can actually be released.

The release is a business process and a business decision.

When people say that they are releasing the software, they typically mean a crucial step of the release process. That could be the sign-off to allow the deployment. That could be informing clients that the software is finished.

The deployment is more clearly defined…


Image by Martin Thoma

STRIDE is a model which categorizes threats into…


“If everything seems under control, you’re not going fast enough”

Female holding a computer in front of servers
Female holding a computer in front of servers
Photo by Christina Morillo (original). Thank you!

Almost all web services for end-users have the need to store data. Almost all of them store them in a database. And quite a lot use a relational database like PostgreSQL, MySQL/MariaDB, or MSSQL. Database systems are pretty awesome because you can forget about them. They just handle the data persistence for you… until they get slow.

In this article, you will learn the difference between vertical and horizontal partitioning, sharding, replication, and a few other ways to speed up your database. Let’s go!

What Do We Care About?

For database systems, we care a lot about consistency and availability. We also need a working…


Be smart or throw money at the problem

Image by Martin Thoma

The beauty of software development is that almost arbitrary many can profit from a developer’s work. Web services such as Facebook or YouTube have several hundred developers, but hundreds of millions of users. However, having many users is not for free. The servers need to do more work. At some point, the machine you started with is not enough.

After reading this article, you will know the difference between scaling vertically and scaling horizontally. Let’s go!

Vertical Scaling: Scaling up💸

The simplest solution when your server struggles is to buy a more powerful one. It might be more RAM, a better CPU, or a…

Martin Thoma

I’m a Software Engineer with focus on Security, Data Science, and ML. I have over 10 years of experience with Python. https://www.linkedin.com/in/martin-thoma/

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store