@meterio/scan-sync

    0.2.66 • Public • Published

    Scan Sync

    Scan the Meter blockchain and transform interested data into a MongoDB.

    Workflow

    +----------------+       +--------------+        +----------------+
    |                |       |              |        |                |
    | Meter FullNode +-----> +   Base DB    +------->+ Defined Entity |
    |                |       |              |        |                |
    +----------------+       +--------------+        +----------------+
    
    • Base DB: Blocks/TXs/PowBlocks/PowTxs/Receipts
    • Defined Entity: Balances/Transfers/ etc

    Features

    • Blocks/TXs/Receipts
    • Committee/Epoch
    • MTR/MTRG Native Balance and Transfer
    • MTR/MTRG System Contract Transfer
    • ERC20 Token Balance and Transfer
    • Staking Engine (incomplete)
    • Auction Engine (incomplete)
    • AccountLock Engine (incomplete)

    Usage as Cli

    1. Install dependency
    npm install -g @meterio/scan-sync dotenv-cli
    
    1. Prepare env file with these information
    # database
    MONGO_PATH=127.0.0.1:27017/scandb
    MONGO_PWD=scan
    MONGO_USER=scan
    MONGO_SSL_CA=
    
    1. Run sync
    dotenv -e env.prod scan-sync main pos

    Usage with Typescript

    ts-node main.ts [Network] [Task]
    
    Network: [main|test]
    Task: [pos|pow|balance|erc20|committee]
    

    Daemon

    nohup dotenv -e env.prod scan-sync main pos >> ~/pos-sync.log 2>&1 &
    

    Keywords

    none

    Install

    npm i @meterio/scan-sync

    DownloadsWeekly Downloads

    150

    Version

    0.2.66

    License

    MIT

    Unpacked Size

    860 kB

    Total Files

    353

    Last publish

    Collaborators

    • avatar
    • avatar