MAPO Developer Docs
LearnDevelopRunWhitePaperBRC-201
English
English
  • Overview
  • Learn
    • About MAP Protocol
      • Background
      • Introduction of MAP Protocol
      • History of MAP Protocol
    • Comparison with other cross-chain models
      • MAP Protocol vs Cosmos & Polkadot
      • MAP vs other cross-chain solutions without relay chain
    • Technical Mechanism
      • MAP Protocol's Technical Mechanism
      • Three-layer Architecture
      • MAP Protocol Layer
        • Concept
        • Isomorphism with All Chains
        • Verification & Maintenance Network
      • MAP Omnichain Service (MOS) Layer
      • MAPO Application Layer
      • Peer-to-Peer Cross-chain Technology with ZK-enabled Light Clients
      • Interact with Bitcoin
    • Gas Fee Model
    • DAO
    • Construction of MAP Protocol
      • Developers
      • Validators
      • Maintainers
      • Messengers
      • Liquidity providers
      • End users
    • Tokenomics
    • Purchase $MAP
  • Develop
    • MAP Relay Chain
      • Getting Started
        • Build
        • Make Private Chain
        • How To Vote
        • How To Withdraw
        • Integrate an Exchange
        • Integrate MAP Relay Chain with EVM-Compatible Chains
      • Consensus
        • Overview
        • Proof-of-Stake
        • Validator
          • Validator
          • Locked MAP
        • Election
        • Rewards
        • Aggregated Seal
      • Contracts
        • Precompiled Contracts
        • Genesis Contracts
          • ABI
            • AccountsABI
            • ElectionABI
            • EpochRewardsABI
            • LockedGoldABI
            • ValidatorsABI
          • Deploy
      • Marker
        • Genesis
        • Validator
        • Vote
        • ContractOwner
        • Common
      • Account-Abstraction
    • Light Client
      • Verification based on Light Client
      • MAPO Light Client
        • EVM Chains
        • Near
      • Light Clients
        • Client Manager
        • BNB Smart Chain
        • Near Protocol
        • Polygon(Matic)
        • Ethereum 2.0
        • Klaytn
        • Conflux)
      • Maintainer
    • MAP Omnichain Service (MOS)
      • MOS Message Guides
        • How It Works
        • How To Use
        • EVM Chains Contract
      • MCS Guides
        • How It Works
        • How To Use
          • How To On Evm Chains
          • How To On Near Protocol
        • Relay Chain Contract
        • EVM Chains Contract
        • Near Protocol Contract
      • Messenger
      • API
    • OmniChain Examples
      • OmniApp
      • OmniDictionary
    • API & SDK
      • Butter SDK
      • Atlas JSON RPC
      • Atlas Consensus API
      • MAP Scan API
    • Connected Chains and Corresponding Addresses
  • Run
    • How To Become A New Validator
    • How To Become A New Validator[advanced]
    • Withdraw
Powered by GitBook
On this page
  • Updating the Active Validator Set
  • Election Validator
  • Implementation

Was this helpful?

  1. Develop
  2. MAP Relay Chain
  3. Consensus

Election

PreviousLocked MAPNextRewards

Last updated 2 years ago

Was this helpful?

Introduction to Map chain validator elections and management of validator and votes throughout the process.

Updating the Active Validator Set

The active validator set is updated by running an election in the final block of each epoch, after processing transactions and Epoch Rewards.

Election Validator

Validators must have at least 0.001 proportion of the total votes to be considered for the election. So the validator can't have no votes.

The advantage of this is to avoid burn MAP and limit the number of voters in the 1000.

There is a minimum target(1) and a maximum cap(100) on the number of active validators that may be selected. If the minimum target is not reached, the election aborts and no change is made to the validator set this epoch.

EXAMPLE: Now there are four validators on the chain,they are:

["0x1c0eDab88dbb72B119039c4d14b1663525b3aC15", "0x16FdBcAC4D4Cc24DCa47B9b80f58155a551ca2aF", "0x2dC45799000ab08E60b7441c36fCC74060Ccbe11", "0x6C5938B49bACDe73a8Db7C3A7DA208846898BFf5"]

If we do not select validators for some reasons (equivalent validators number to less than 1), we will continue to use the above validators. If we select the latest set of validators (which means that the number of new validators is greater than 1 and less than 100), we will replace the above validators with new validators.

Implementation

manages Locked Map voting and epoch rewards and runs Validator Elections.

Election.sol