☁️
Zus Docs
  • About Züs
  • System
    • Providers and Services
      • Miner
      • Sharder
      • Blobber
      • Validator
      • Authorizer
      • Node Locator (0DNS)
    • Storage
      • Architecture and Data Management
      • Protocol
        • Allocations
        • Reference Objects
        • Challenges
        • Write Markers
          • Chain Hashing
          • Two Commit
        • Blobber Repair Protocol
      • ZS3 Server
        • Backup, Recovery and Replication
        • Encryption and Compression
        • S3FS Setup and Usage
        • Backup & Recovery with Restic on Blimp + ZS3 Server
        • Backup & Recovery with Veeam on Blimp + ZS3 Server
      • File Operations
        • Upload
        • Download
        • File Sharing
        • Partial Error Recovery
        • Streaming
        • Rent a Blobber
    • Smart Contracts
      • Storage S.C.
      • Miner S.C.
      • ZCN S.C.
      • ERC-20 S.C.s
      • Bridge Protocol
    • Blockchain & Consensus
      • Entities
    • User Authentication and Wallet Management System
      • OKTA Integration
      • Key Management System (KMS)
  • APIs
    • 0DNS API
    • JS API
    • Mobile API
  • CLIs
    • Storage CLI
      • Quickstart
      • Configuring the tool
    • Wallet CLI
      • Wallet Configuration
      • Quickstart
      • Configuring the tool
  • SDKs
    • Go SDK
      • GO SDK Microservices
    • JS SDK
  • Tokenomics
    • Staking
    • Reward & Penalty
  • ✨Züs Apps
    • 🗝️Vult
      • Getting Started
        • Web
        • Mobile
      • Vult AI
        • Batch Processing
        • Memory Retention
        • Technical Implementation
        • Architecture Overview
      • Login / Register
      • File Management Pages
      • File Sharing
      • Storage Management Dashboard
      • Storage Maintenance and Troubleshooting
      • Züs Subscription
      • Wallet Management
      • Refer a friend
      • Settings
    • 🏗️Blimp
      • Getting Started
      • Login / Register
      • Configure Storage
        • Create Standard Storage Allocation
        • Create Enterprise Allocation
        • Create S3 Server Allocation
        • Create Cloud Migration Allocation
        • Allocation Maintenance and Troubleshooting
      • File Management Pages
      • File Sharing
      • Manage Allocations
      • Upgrade Storage
      • Blimp Vault
      • Refer a friend
      • Settings
      • Launching ZS3 Server
      • Using CLI to backup files into Blimp + ZS3 Server
    • 🏠Chimney
      • Getting Started
      • Login / Register
      • Create New Deployment
      • Manage Your Deployments
      • Homepage
      • Staking Dashboard
      • Rank Dashboard
      • Monitor Dashboard
      • Stats Dashboard
      • Logs Dashboard
      • Wallet Dashboard
      • Operations on your Deployments
      • Restricted Blobbers
      • Settings
        • Manage Profile
        • Wallet Settings
        • Update Blobber Settings
        • Update Blobber Version
        • Refer a friend
        • Help
    • 🌐Atlus
      • Getting Started
      • Home page
      • Service Providers Page
      • Charts Page
        • Market Charts
        • Network Charts
        • Storage Charts
      • Blockchain Page
      • Server Map Page
      • Storage Explainer Page
      • Details Pages
        • Block Details Page
        • Transaction Details Page
        • Wallet Details Page
        • Miner Details Page
        • Sharder Details Page
        • Blobber Details Page
        • Validator Details Page
        • Authorizer Details Page
        • Allocation Details Page
      • Appendix: Common Components
    • ⚡Bolt
      • Getting Started
        • Web
        • Mobile
      • Login / Register
      • Sign In with external wallet
      • Staking Dashboard
      • Staking/Unstaking a provider
      • Claiming Rewards
      • Send/Receive ZCN tokens
      • Buy ZCN
      • Deposit/Withdraw ZCN tokens
      • Activity Dashboard
      • Refer a friend
      • Settings
  • Releases
    • Hardfork
Powered by GitBook
On this page
  • Rewards
  • Penalty
  1. Tokenomics

Reward & Penalty

Rewards

To keep track of challenge pool fraction related to a particular blobber-allocation pair integral value was introduce. It behaves exactly the same way and should be always in sync with corresponding challenge pool. It means, that the summary of integral values for every blobber for a current allocation is exactly the challenge pool balance for any moment in time.

Partition management

Blobber is added to the partition for block rewards calculation on every first challenge passed this rewards period. All the fields in BlobberRewardNode except ChallengesPassed are fixed for that moment, only ChallengesPassed will be updated next time challenge is passed.

Reward amount calculation

Reward is calculated based on time unit values. All the available for reward values are stored in blobber allocation itself in ChallengePoolIntegralValue field. It is reduced every time reward is calculated

            rdtu = (allocation.Expiration - PreviousCompletedChallenge.Created) / timeunit
            dtu  = (CurrentCompletedChallenge.Created - PreviousCompletedChallenge.Created) / timeunit
	    reward = (dtu / rdtu) * float64(d.ChallengePoolIntegralValue)
	    d.ChallengePoolIntegralValue -= reward

If intervals dtu are even, then rewards will be split evenly between the intervals for constant ChallengePoolIntegralValue (it will be spent evenly in the intervals).

Reward then is split in two part, blobberReward and validatorReward using provided in config ratio.

        validatorsReward = reward * config.validator_reward
        blobberReward = reward * (1 - config.validator_reward)

Reward value is also adjusted to the success rate of a blobber. If rewards are adjusted, difference is taken from challenge pool and burnt.

        partial = float64(challenge.SuccessfulTickets) / float64(challenge.TotalValidators / 2)
        blobberReward = blobberReward * partial

Reward distribution

Reward amount is distributed among all the blobbers evenly. Every blobber distributes its fraction of rewards according to standard algorithm among all the delegates.

  • If provider doesn't have any delegates, then all the rewards go to provider's stake pool

  • If service charge is set, then provider will be guaranteed to receive service charge

  • Then value left is split among all the delegates of a provider proportionally with their weight

		stakePool.Reward = stakePool.Reward + value
		sp.Reward = stakePool.Reward + serviceCharge
		valueLeft = value - serviceCharge
	        for id, pool := range sp.Pools {
		    ratio := pool.Balance / totalStake
		    reward := valueLeft * ratio
                    delegate.Reward = delegate.Reward, reward
                    valueLeft = valueLeft - reward
                }

Validator rewards

  • Validators get rewards when a challenge response is computed, whatever the status of the challenge is.

  • All the validators of the challenge get an equal share of the total share of the validators from the challenge rewards.

  • This reward is calculated as follows:

     validatorsReward = challenge_reward * config.validator_reward

where config.validator_reward is a constant value set in the configuration file sc.yaml. Refer to Blobber Rewards section for more details on the challenge reward.

Penalty

Blobber Penalty

  • Penalty is incurred on a blobber for all the challenges that this blobber failed to verify.

  • Penalty is slashed from the blobber's stake pool when the blobber tries to redeem a successful challenge, where the smart contract checks whether the last challenge (before the one being processed) was accepted or not, if not, the slashing process is executed over this blobber.

  • The blobber is penalized for the time period between the latest successful challenge and the latest finalized challenge (described in the system's time_unit) w.r.t the time remaining until the expiration of the allocation as follows:

rdtu := time.Duration(alloc.Expiration - latestSuccessfulChallenge) / conf.TimeUnit
dtu := time.Duration(latestFinalizedChallenge - latestSuccessfulChallenge) / conf.TimeUnit
move := (dtu / rdtu) * ChallengePoolIntegralValue // ChallengePoolIntegralValue total token value in the challenge pool
move = move - validatorRewards // refer to rewards page for the calculation of validatorRewards
penalty = move * conf.BlobberSlash // BlobberSlash is mentioned down in the config variables
  • This penalty amount will be slashed from the blobber's stake pool, and the move amount will be moved back from the challenge pool to the allocation write pool.

  • Penalty calculation depends on a couple of configuration variables:

    • storagesc.time_unit in sc.yaml: a duration that it's considered the unit of time for the time calculations for challenges, allocations and other operations related to the storage smart contract. For example, If the expiration of the allocation is 3 this means it's 3 * time_unit.Used in the calculation of rdtu and dtu

    • storagesc.validator_reward in sc.yaml: defines the ratio of the challenge reward that goes to all the validators of the challenge. This is deducted from the challenge reward before the slashing happens.

    • storagesc.blobber_slash in sc.yaml: defines the ratio of the challenge reward that will be slashed from the blobber's stake pool as a penalty for the failed challenge.

PreviousStakingNextZüs Apps

Last updated 1 month ago

time points related to penalty calculation