We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
{ RootKey // 管理员地址 TotalStakePower // 全网总算力 MaturePeriod // 成熟期 RoundPeriod // 奖励发放周期 PrincipalUnlockDuration // 本金锁定期 MinDepositAmount // 最小充值金额 MaxRewardsPerRound // 每轮最大总奖励 InflationFactor // 通胀系数 LastRoundReward // 上一轮实际总奖励 NextRoundEpoch // 下一轮奖励发放高度 // 在锁定状态的本金 LockedPrincipalMap { Address => []{Id, Amount, ChainEpoch}, } // 已解锁的本金 AvailablePrincipalMap { Address => Amount } // 各地址的算力情况 StakePowerMap { Address => StakePower (=AvailablePrincipal + LockedPrincipal中已成熟部分) } // 待释放的奖励 VestingRewardMap { Address => []VestingFund } // 可提取的奖励金额 AvailableRewardMap { Address => Amount } }
{ // 充值 func Deposit() // 提取本金 func WithdrawPrincipal(amount) // 提取奖励 func WithdrawReward(amount) // 修改成熟期,需鉴权 func ChangeMaturePeriod() // 修改轮长,需鉴权 func ChangeRoundPeriod() // 修改锁定期,需鉴权 func ChangePrincipalUnlockDuration() // 修改最小充值金额,需鉴权 func ChangeMinDepositAmount() // 修改每轮总奖励上限,需鉴权 func ChangeMaxRewardsPerRound() // 修改通胀系数,需鉴权 func ChangeInflationFactor() // 修改管理员,需鉴权 func ChangeRootKey() // 定时器 func OnEpochTickEnd() }
lotus stake deposit [amount]
lotus stake info
lotus stake list-locked-principal
lotus stake list-vesting
lotus stake withdraw principal [amount]
lotus stake withdraw reward [amount]
The text was updated successfully, but these errors were encountered:
管理员可调整!!!这个还是去中心化的项目吗?
Sorry, something went wrong.
你好,管理员账号 t080 是 filecoin 就有的机制,https://github.com/filecoin-project/lotus/blob/b54b1303f9f6bcc3b57ae25cfc1174b59f44b943/chain/actors/builtin/builtin.go#L31 它是一个多签地址,需要多位管理员同意才能调用,filestar也打算沿用这套管理方案。
t080
参数可调整的好处在于更新规则不需要额外发布代码进行硬分叉,同时如果发现bug也可以在不更新代码的情况下及时停止stake。
管理员账号在stake中的作用仅限于参数的调整,不能因此获利。
No branches or pull requests
FileStar Stake 方案
基本逻辑
规则
伪代码实现
新增命令
lotus stake deposit [amount]
lotus stake info
lotus stake list-locked-principal
lotus stake list-vesting
lotus stake withdraw principal [amount]
lotus stake withdraw reward [amount]
The text was updated successfully, but these errors were encountered: