dApp Staking v3 Technical Overview
Introduction
Astar and Shiden networks provide a unique way for developers to earn rewards by developing products that native token holders can decide to support.
The principle is simple - stakers lock their tokens to stake on a dApp, and if the dApp attracts enough support, it is rewarded in native currency, derived from the inflation. In turn stakers are rewarded for locking & staking their tokens.
The following chapters will provide an overview of the functionality and terminology with accompanying examples.
Functionality Overview
Eras
Eras are the basic time unit in dApp staking and their length is measured in the number of blocks.
Eras are not expected to last long, e.g. current production networks era length is roughly 1 day (7200 blocks). After an era ends, it's usually possible to claim rewards for it, if staker or dApp are eligible.
Periods
Periods are another time unit in dApp staking. They are expected to be more lengthy than eras. Each period is denoted by a number, e.g. 1, which increments each time a new period begins.
Each period consists of two subperiods:
Voting
Build&Earn
Period beginning is marked by the Voting
subperiod, after which follows the Build&Earn
subperiod.
Stakes are only valid throughout a period. When new period starts, all stakes are reset to zero. Protocol dynamic prevents inactive projects having high stakes due to inertia of stakers while at the same time allows more visibility for dApps joining the protocol and equal chance in attracting stakers' attention.
Even though stakes are reset, locks (or freezes) of tokens remain.