zoukankan      html  css  js  c++  java
  • PeerSim中一些自己的理解

         PeerSim是用Java语言写的可以模拟P2P系统的软件。刚开始看。有一些比较晦涩的地方,记录一下自己的理解。

    1、这个模拟器的运行过程:

         Simulation ---> read config file ---> set up network (nodes, protocols) ---> initialization (init states of protocols) (Control object) ---> driven engine

    2、Simulation model: 1) network size

                                      2) protocols –> to initialization

                                      3) control –> to monitor some properties –> to modify some parameters

                                      4) Simulator <config.txt>

    3、interfaces:

            Node: network address, contain protocols

            CDProtocol: periodic activity

            Linkable: neighbers in network

            Control: observe and modify the network

    4、Configuration file entries:

            <properties>.<component>[.<parameter>]  [full_path]classname

                     |___________|

                                |_____>mapped to a index(#)

            空格之前的部分叫做Key, 空格之后的叫做Value

            PeerSim可以自动搜索CLASSPATH来确定classname的位置,所以一般不用指定full_path

    5、include.init <> <> … 定义了哪些Initializer 可以运行,并且规定了它们的运行顺序。如果没有指定(即没有include.init这一项),默认是字母顺序执行。

         include还可以有include.protocol <>  和 include.control <> 选项。

          [1] PeerSim HOWTO 1: http://peersim.sourceforge.net/tutorial1/tutorial1.html

  • 相关阅读:
    1015,存储过程,视图
    1009,数据库查询,聚合函数,日期时间函数
    1008,数据库表格创建,名称,格式

    公历和农历转换的JS代码
    面向对象之封装
    HTML之锚点
    HTML之css+div
    HTML基础
    SQL之定义变量
  • 原文地址:https://www.cnblogs.com/wangshuo/p/2072539.html
Copyright © 2011-2022 走看看