Ergo is being used currently by a lot of exchanges, services, wallets, mining pools, and so on, and there are hundreds of nodes in the network.
Thus changing the protocol via a hard-fork (when old nodes will stop syncing after a turning point) is painful and often controversial (as agreement from all the community is needed, and it is hard to obtain it usually).
Thus it is usually much less controversial then to do protocol upgrades via soft-forks, when old nodes can process blocks after switching to a new protocol version. Ergo protocol has support for voting for a soft-fork and automatic activation in case of supportive super-majority since mainnet launch. In some cases there can be other ways to perform soft-forks which are more efficient, but usually the in-built soft-forking protocol would be enough.
Every header contains three bytes to store votes. Up to 2 bytes can be used to vote for changing network parameters (such as block size), and vote for soft-fork is also going there. Every parameter to vote on has an identifier, and there is a special identifier for indicating a vote for soft-fork(120).
To start voting, a miner needs to put the identifier at the first block of an epoch. Voting epochs are the same as difficulty readjustment epochs,
one epoch is about 1,024 blocks.
When the reference client is used by a miner, proper data will be put into headers automatically, what the miner’s node needs is that certain value in the config, but in case of voting for a soft-fork proper config is provided with the client.
Specifically, for the next soft-fork, we need for ergo.node.protocolVersion parameter to be set to 3 :
ergo{
chain{
protocolVersion = 3
}
}
Then miner will start voting or vote automatically. The value above will be provided with node version 5.+.
The voting for soft-fork lasts for 32 epochs (32,768 blocks ~ 46 days), 90+% support is needed to activate the protocol upgrade.
After voting, there is activation period of 32 epochs (32,768 blocks as well). The block version will be increased after the activation period, and increased block version will be considered during blocks validation.