Skip to content

Latest commit

 

History

History
48 lines (34 loc) · 2.74 KB

BEP128.md

File metadata and controls

48 lines (34 loc) · 2.74 KB

BEP-128: Improvement on BNB Smart Chain Staking Reward Distribution

1. Summary

This BEP describes a proposal to improve the BNB Smart Chain staking reward distribution mechanism on BNB Beacon Chain.

2. Abstract

Instead of distributing BNB Smart Chain staking rewards in a single block for each day, this proposal suggests distributing staking rewards in many consecutive blocks, to minimize the burden on the specific block.

3. Status

This BEP is already implemented.

4. Motivation

Currently, the staking rewards of BNB Smart Chain are distributed in the first block of a day on BNB Beacon Chain (which is known as breath block). With the increasing number of delegators (more than 50,000 nowadays), it will lead to a heavy load to breath block, and users' transactions/requests could be affected. Meanwhile, it could also be a bottleneck for further evaluation of BNB Beacon Chain. Thus, this proposal provides a solution to fix the issue and benefit the evaluation of BNB Beacon Chain in the long term.

5. Specification

5.1 Overall Workflow

overall workflow

The overall distribution processes work like this:

  • In breath block, validators' commission fee will be distributed, all delegators' rewards will be saved to a separate store.
  • Delegators' reward will be distributed in batches in the following blocks.

5.2 Distribution Batch Size

Distribution batch size controls how many delegators will receive reward in a single block. It should be evaluated and adjusted to make sure:

  • The reward distribution must finish within one day, which means the batch size should not be too small.
  • It should not be too big to bring heavy load on a single block.

At the same time, this batch size can also be governed.

5.3 User Impact

The impact to general delegators is minimal, that their rewards will be delayed a bit after applying this proposal. However, the delay is relatively small and can be ignored compared to the whole staking process. Taking the current delegation volume as an example, about 50,000 rewards are distributed, then in the worst case the delay is 3~4 minutes (500 blocks) if the batch size is 100.

6. License

The content is licensed under CC0.