In software engineering, a fork consists of a “split” of a project, as developers take the source code to start independently developing on it. Software protocols (the set of rules underlying the software) usually fork as a group decision-making process. All developers have to agree on the new course and direction of the software protocol. A fork can be “soft” when an alteration to the software protocol keeps it backward compatible or “hard” where a divergence of the new chain is permanent. Forks are critical to the development and evolution of Blockchain protocols.
What are soft forks and hard forks?
In a Blockchain, a soft fork occurs when an alteration to the software protocol keeps it backward compatible. In other words, the new forked chain follows new rules while also honoring the old rules.
In a hard fork, a divergence of the new chain is permanent. Nodes running older versions will no longer be accepted by (or be able to communicate with) the new version.
Understanding soft forks and hard forks
When a consumer updates a digital banking app on their smartphone, the process is painless and seamless. Updates only take a few minutes and some apps do so automatically. What’s more, there are rarely any usability issues with the new version.
Open-source cryptocurrencies are very different. There is no central authority releasing updates or making changes as it sees fit. There is also no requirement for Bitcoin users to understand the code that underpins it. Nevertheless, freely accessible code is an important facet of a decentralized, open-source platform.
Soft and hard forks are the cryptocurrency versions of updates for computer programs, allowing networks to be upgraded in the absence of a central authority. Forking as a term describes any scenario where a cryptocurrency project needs to make technical updates to its code.
Forking necessitates that a Blockchain splits into two branches. The nature of the split can be categorized as either hard or soft.
In the next section, we’ll take a look at each in more detail.
As noted earlier, a soft fork is backward compatible with the original chain continuing to follow old rules. Upgraded nodes can still communicate with non-upgraded nodes, which is another way of stating that new rules do not clash with old rules.
This kind of fork requires that a majority of miners upgrade before the new rules are enforced. A recent example of a soft fork is the Segregated Witness (SegWit) fork which occurred after the Bitcoin/Bitcoin Cash split. This update changed the format of transactions and blocks, but old nodes could still validate them without breaking the rules.
Hard forks are backwards-incompatible updates. Since nodes add rules that conflict with older nodes, new nodes can only communicate with those operating on the latest version.
Here, the blockchain must split into two, parallel chains that continue to propagate blocks and transactions separately. One operates under the old rules while the other under the new rules.
It’s important to note that until the point of divergence, each separate chain has a shared history. If a user held Bitcoins before the split, they end up holding coins on each of the two subsequent chains.
An example of a hard fork is the 2017 split that saw Bitcoin separate into two chains: Bitcoin and Bitcoin Cash. This occurred before the aforementioned SegWit soft fork and was the result of disagreement over increasing the block size.
Since an increase in block size required a rule change, nodes only accepted blocks smaller than 1MB. This meant that an otherwise valid 2MB block would be rejected and thus be incompatible with the previous version.
- Forking helps cryptocurrency Blockchain make important updates to its code in the absence of a central authority. Hard and soft forks describe the nature of these updates as Blockchain networks split in two.
- A soft fork is backward-compatible with the original chain. Older nodes can communicate (and are compatible with) new nodes without breaking rules.
- A hard fork is backward-incompatible with the original chain. This split is a permanent divergence from a previous version of the Blockchain. As a result, nodes running previous versions are no longer compatible with the newest version.
Main Free Guides: