# Activation Protocol
New versions of Waves software bring new features. Those new features should be activated by many nodes at the same time. Previously the features were activated by timestamps. That put node owners in a tight time frame to update their nodes. Failure to update a node in time led to unintentional forks. The Feature Activation Protocol gives Waves community the ability to apply new features with a suitable pace. Or not apply some of them at all. For details about API methods related to Feature Activation Protocol, see Activation article of the Node API chapter.
# Features Identification
Each new feature is assigned with unique sequential number. List of new features with their IDs will be provided with each new release.
New features come with new versions of node’s software. Different versions can operate identically until activation of new features. After activation of a feature the network will diverge in two parts: nodes that implement the feature and nodes that do not.
# Feature Statuses on Blockchain
A feature status is stored on the blockchain. The initial feature status is
Voting which can be then changed to
Approved - meaning that the feature received the required number of votes from miners. After a defined period (number of blocks) the
Approved features get
Activated status. From that moment (block) the nodes that implement the feature start to operate in a new way.
Voting is performed by miners. If a miner supports a feature and wants to vote for it he has to put the feature number (ID) in the list of supported features in the
features section of configuration file. After that every block generated by this miner will contain the IDs of supported features. For details about
features section of the node configuration file, see Features Settings section of the Node Configuration article.
On Mainnet every 10000 blocks the node sums up the number of blocks with support for a feature. If a feature was supported in more than 80% of blocks during the last calculation period it becomes Approved. Otherwise, the voting continues and can take another voting period or more.
Note: See Stagenet and Testnet voting conditions.
If the node sees that a new feature was approved, but the node does not implement it, it will log the warning message about the upcoming activation of an unsupported feature.
Before an approved feature becomes Activated another 10000 blocks have to pass. This period is intended for the update of non-mining nodes to a new version.
If a new feature was activated but the node was not updated to support it, the node will shutdown itself (default behavior) and log the error about activation of the unsupported feature.
⚠️ On the Testnet approval and activation periods are set to 3000 (100 blocks on Stagenet) blocks each. This allows faster activation of new features for testing purposes.
In version 1.0.0 a new cool feature was introduced. It has ID
SuperMiners with a total stake of 40% supports the feature. Administrator of
SuperMiners updates the node from version 0.9.9 to 1.0.0. And adds
123 to the list of supported features in the configuration file.
SuperMiners node starts to put ID
123 into each mined block since height 1228765. Other miners did not support the feature and only some of them updated their nodes to version 1.0.0.
At block number 1230000 the nodes calculated that only 50% of blocks support the feature
123. So, the status of feature stays unchanged, the voting was unsuccessful for the period and it continues.
During the next 10000 blocks
SuperMiners convinced few smaller miners to support the feature. On block 1240000 it turns out that the feature is supported in 9102 of last 10000 blocks. That means 91%. So, the status of the feature changed to approved. At this moment nodes that run on version 0.9.9 and earlier warn their owners about the approval of an unsupported feature.
At block 1250000 the feature number
123 will be activated and nodes version 1.0.0 and above will start to use it. Nodes on earlier versions will stop working.