• 以太坊:选择以太坊客户端


    选择以太坊客户端

    There are many Ethereum clients to choose from. We recommend different clients depending on whether you are developing or deploying.

    When developing

    Ganache

    We recommend Ganache, a personal blockchain for Ethereum development that runs on your desktop. Part of the Truffle Suite, Ganache simplifies dapp development by placing your contracts and transactions front and center. Using Ganache you can quickly see how your application affects the blockchain, and introspect details like your accounts, balances, contract creations and gas costs. You can also fine tune Ganache’s advanced mining controls to better suit your needs. Ganache is available for Windows, Mac and Linux, and you can download it here.

    Ganache, when launched, runs on http://127.0.0.1:7545. It will display the first 10 accounts and the mnemonic used to create those accounts. (Read more about account mnemonics.) The mnemonic will persist across restarts of Ganache, though it can be changed to be randomly generated. You can also input your own.

    **Warning**: Do not use this mnemonic on the main Ethereum network (mainnet).

    Truffle Develop

    We also recommend using Truffle Develop, a development blockchain built directly into Truffle. Truffle Develop helps you set up an integrated blockchain environment with a single command, no installation required. Run Truffle Develop by typing the following into a terminal:

    truffle develop
    

    This will run the client on http://127.0.0.1:9545. It will display the first 10 accounts and the mnemonic used to create those accounts. (Read more about account mnemonics.) When you run truffle develop for the first time it will generate a random mnemonic that will persist for you and you alone.

    **Warning**: Do not use this mnemonic on the main Ethereum network (mainnet). If you send ETH to any account generated from this mnemonic, you will lose it all!

    Once launched, Truffle Develop will provide you with a console you can use to run all available Truffle commands. These commands are input by omitting the truffle prefix. So, for example, to compile your smart contracts, instead of typing truffle compile, you need to only type compile.

    To read more about interacting with the console, please see the Using the Console section.

    Ganache CLI

    Ganache also has a command-line interface for those who aren’t working from a graphical environment. Great for automated testing and continuous integration environments, Ganache CLI runs headless and can be configured to serve all your development needs. Ganache CLI processes transactions instantly instead of waiting for the default block time, so you can test that your code works quickly. It also tells you immediately when your smart contracts run into errors, and integrates directly with Truffle to reduce test runtime up to 90% compared to other clients. Learn more about Ganache CLI.

    Deploying to live networks

    There are many official and unofficial Ethereum clients available for you to use. The following is a short list:

    These are full client implementations that include mining, networking, blocks and transaction processing. You should use these clients after you’ve sufficiently tested your dapp with Ganache or Truffle Develop and you’re ready to deploy to your desired Ethereum network.

    Deploying to private networks

    Private networks utilize the same technology as with live networks, but with a different configuration. So you can configure any of the Ethereum clients mentioned above to run a private network, and deploy to it in exactly the same way.

    Next  Previous

  • 相关阅读:
    maven surefire入门
    编译原理随笔4(自下而上的语法分析-递归法)
    编译原理随笔3(自上而下的语法分析-推导法)
    编译原理随笔1
    LeetCode刷题笔记-DP算法-取数问题
    算法刷题笔记-stack-四则运算
    LeetCode刷题笔记-递归-反转二叉树
    Beta里程碑总结
    评价cnblogs.com的用户体验
    我们的团队目标
  • 原文地址:https://www.cnblogs.com/hzcya1995/p/13313070.html
Copyright © 2020-2023  润新知