EOS踩坑记 2

1、--contracts-console

  在开发模式下,需要将 nodeos 添加此选项。

  

  

2、Debug Method

  The main method used to debug smart contract is Caveman Debugging, where we utilize the printing functionality to inspect the value of a variable and check the flow of the contract.

  原始人调试法(Log 调试法)

  Printing in smart contract can be done through the Print API. The C++ API is the wrapper for C API, so most often we will just use the C++ API.

3、If no optional arguments are used (i.e. --url and --wallet-url), cleos automatically tries to connect to a locally running eos node (i.e. nodeos).

4、nodeos --plugin

--plugin eosio::chain_api_plugin

  也可以在 cofnig.ini 中配置

  

plugin = eosio::chain_api_plugin

5、nodeos -h 可以查看 plugin 有哪些option可以设置
  

6、cleos system

  

  

7、p2p-peer-address

  通过 config.ini 中的 p2p-peer-address 可以配置要联接的主网结点,使得当前结点可以加入主网。

  

# Default p2p port is
p2p-peer-address = 123.255.78.9:

8、Non-Producing Node

  A non-producing node is a node that is not configured to produce blocks. An example use case would be to provide a synchronized node that provides a public HTTP-RPC API for developers or as a dedicated private endpoint for your app.

  You need to set some peers in your config ini, for example:

    p2p-peer-address = 106.10.42.238:9876

  Or you can include the peer in as a boot flag, like so:

    --p2p-peer-address=106.10.42.238:9876

  只需指定 p2p-peer-address,就这么简单。详情见参考[3]。

9、nodeos 单节点常用选项

    # Enable production on a stale chain, since a single-node test chain is pretty much always stale
enable-stale-production = true
# Enable block production with the testnet producers
producer-name = eosio
# Load the block producer plugin, so you can produce blocks
plugin = eosio::producer_plugin
# As well as API and HTTP plugins
plugin = eosio::chain_api_plugin
plugin = eosio::http_plugin
# This will be used by the validation step below, to view history
plugin = eosio::history_api_plugin

10、EOSIO Core Network

  

11、EOSIO Access Network

  

  1)API Node

    API nodes handle requests from cleos to perform transactions and query state. API nodes communicate with cleos via http, and with other nodeos nodes using the EOSIO networking protocols.

    Each producer node should have at least one associated API node.

  2)Seed Node

    Seed nodes communicate with other nodeos nodes in order to maintain synchronization with the producer nodes. Seed nodes might be producer candidates that are maintaining synchronization with producers and servicing other nodes.

    Each producer node should have at least one associated seed node.

12、EOSIO Consumer Network

  

参考:

1、https://developers.eos.io/eosio-cpp/docs/debugging

2、https://developers.eos.io/eosio-nodeos/docs/environment-producing-node

3、https://developers.eos.io/eosio-nodeos/docs/environment-non-producing-node

EOS踩坑记 2的更多相关文章

  1. EOS踩坑记

    [EOS踩坑记] 1.每个account只能更新自己的contract,即使两个account的秘钥相同,也不允许. 如下,使用alice的权限来更新james的contract.会返回 Missin ...

  2. Spark踩坑记——Spark Streaming+Kafka

    [TOC] 前言 在WeTest舆情项目中,需要对每天千万级的游戏评论信息进行词频统计,在生产者一端,我们将数据按照每天的拉取时间存入了Kafka当中,而在消费者一端,我们利用了spark strea ...

  3. Spark踩坑记——数据库(Hbase+Mysql)

    [TOC] 前言 在使用Spark Streaming的过程中对于计算产生结果的进行持久化时,我们往往需要操作数据库,去统计或者改变一些值.最近一个实时消费者处理任务,在使用spark streami ...

  4. 【踩坑记】从HybridApp到ReactNative

    前言 随着移动互联网的兴起,Webapp开始大行其道.大概在15年下半年的时候我接触到了HybridApp.因为当时还没毕业嘛,所以并不清楚自己未来的方向,所以就投入了HybridApp的怀抱. Hy ...

  5. Spark踩坑记——共享变量

    [TOC] 前言 Spark踩坑记--初试 Spark踩坑记--数据库(Hbase+Mysql) Spark踩坑记--Spark Streaming+kafka应用及调优 在前面总结的几篇spark踩 ...

  6. Spark踩坑记——从RDD看集群调度

    [TOC] 前言 在Spark的使用中,性能的调优配置过程中,查阅了很多资料,之前自己总结过两篇小博文Spark踩坑记--初试和Spark踩坑记--数据库(Hbase+Mysql),第一篇概况的归纳了 ...

  7. djangorestframework+vue-cli+axios,为axios添加token作为headers踩坑记

    情况是这样的,项目用的restful规范,后端用的django+djangorestframework,前端用的vue-cli框架+webpack,前端与后端交互用的axios,然后再用户登录之后,a ...

  8. HttpWebRequest 改为 HttpClient 踩坑记-请求头设置

    HttpWebRequest 改为 HttpClient 踩坑记-请求头设置 Intro 这两天改了一个项目,原来的项目是.net framework 项目,里面处理 HTTP 请求使用的是 WebR ...

  9. vue踩坑记

    vue踩坑记 易错点 语法好难啊qwq 不要把'data'写成'date' 在v-html/v-bind中使用vue变量时不需要加变量名 在非vue事件中使用vue中变量时需要加变量名 正确 < ...

随机推荐

  1. linux下(Window当然也可以)解决idea创建maven项目导入过慢问题

    1.正常创建maven web项目 2.见下图,选择加号 3.弹出的框中填入archetypeCatalog----internal,确定即可

  2. Flex布局-项目的属性

    Flex项目有以下6个属性: order flex-grow flex-shrink flex-basis flex align-self order属性定义项目的排列顺序.数值越小,排列越靠前,默认 ...

  3. mysql命令行使用

    连接数据库   mysql -P 端口号 -h 远程机地址/ip -u 用户名 -p mysql -uroot -p123456 修改数据库密码 mysqladmin -uroot -p123456 ...

  4. glog学习(二):glog主要接口和类分析

    1.glog的主要接口如下. #define LOG(severity) COMPACT_GOOGLE_LOG_ ## severity.stream()#define SYSLOG(severity ...

  5. day 41 标准文档流 浮动

    一.标准文档流 什么是标准文档流 宏观的将,我们的web页面和ps等设计软件有本质的区别,web 网页的制作,是个“流”,从上而下 ,像 “织毛衣”.而设计软件 ,想往哪里画东西,就去哪里画 标准文档 ...

  6. 第3章 Java数组(上): 一维数组和二维数组

    3.数组及排序算法(2天) 3.1 数组的概述 2课时 3.2 一维数组的使用 3课时 3.3 多维数组的使用 3课时 3.4 数组中涉及到的常见算法 3课时 3.5 Arrays工具类的使用 3课时 ...

  7. delphi XML简单处理

    unit Unit1; interface uses Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System ...

  8. pac4j探索(一)之buji-pac4j shiro整合Cas实现单点登录

    https://blog.csdn.net/hxm_code/article/details/79181218 https://blog.csdn.net/hxm_code/article/detai ...

  9. 阅读 Device Driver Programmer Guide 笔记

    阅读 Device Driver Programmer Guide 笔记 xilinx驱动命名规则 以X开头 源文件命名规则 以x打头 底层头文件与高级头文件 重点来了,关于指针的使用 其中 XDev ...

  10. 彻底删除msde2008(请先在控制面板中卸载).bat

    彻底删除msde2008(请先在控制面板中卸载).bat @echo offset /P dv=请确认强制删除MSDE2008(请先在控制面板中卸载),Y=删除,N=退出:if not defined ...