Reward Distribution Contract
rwddist.xsat
rwddist.xsat
This contract mints $XSAT and distributes it to Synchronizers and Validators.
Actions
Mint XSAT and distribute it to validators
TABLE rewardlogs
rewardlogs
scope height
height
params
{uint64_t} height
- block height{checksum256} hash
- block hash{asset} synchronizer_rewards
- the synchronizer assigns the number of rewards{asset} consensus_rewards
- the consensus validator allocates the number of rewards{asset} staking_rewards
- the validator assigns the number of rewards{uint32_t} num_validators
- the number of validators who pledge more than 100 BTC{std::vector<validator_info> } provider_validators
- list of endorsed validators{uint64_t} endorsed_staking
- total endorsed staking amount{uint64_t} reached_consensus_staking
- the total staking amount to reach consensus is(number of validators * 2/3+ 1 staking amount)
{uint32_t} num_validators_assigned
- the number of validators that have been allocated rewards{name} synchronizer
-synchronizer account{name} miner
- miner account{name} parser
- parse the account of the block{checksum256} tx_id
- tx_id of the reward after distribution{time_point_sec} latest_exec_time
- latest reward distribution time
example
TABLE rewardbal
rewardbal
scope
rwddist.xsat
params
{uint64_t} height
- block height{asset} synchronizer_rewards_unclaimed
- unclaimed synchronizer rewards{asset} consensus_rewards_unclaimed
- unclaimed consensus rewards{asset} staking_rewards_unclaimed
- unclaimed staking rewards
example
STRUCT validator_info
validator_info
{name} account
- validator account{uint64_t} staking
- the validator's staking amount
example
ACTION distribute
distribute
authority:
utxomng.xsat
Allocate rewards and record allocation information.
params
{uint64_t} height
- Block height for allocating rewards
ACTION endtreward
endtreward
authority:
utxomng.xsat
Allocate rewards and record allocation information.
params
{uint64_t} height
- block height{uint32_t} from_index
- the starting reward index of provider_validators{uint32_t} to_index
- end reward index of provider_validators
Last updated