Coder Social home page Coder Social logo

iptb-dht-test's Introduction

iptb-dht-test

ìptb-dht-test aims to create stress tests for the DHT being used in ipfs.

ATTENTION: This is currently a WIP work. If you intend to test the js-ipfs, you need to use ipfs/js-ipfs#856, since the js-ipfs DHT cli is not released yet.

Table of Contents

Introduction

In the context of creating stress tests for libp2p-kad-dht, as well as paving the way to create a test bed for the libp2p-kad-dht, this repo was created.

The main focus of these tests are to test two different workloads, which usually are the focus of testing DHTs regarding its scalability. These workloads are churn intensive and lookup intensive. The first aims to test the network with a high number of peers connecting and disconnecting the network, while data is added to the dht and fetched back. The last one main goal is to have constant put and get in the network nodes.

Install

js-ipfs through CLI

Information can be obtained in ipfs/js-ipfs/#through-command-line-tool.

go-ipfs

Information can be ontained in ipfs/go-ipfs#install

IPTB

Information can be obtained in ipfs/iptb#install

IPTB Plugin

Needs to install plugin for using js-ipfs. Information can be otained in ipfs/iptb-plugins

Usage

With this tool, we can create a DHT simulation, as well as visualize the results obtained from previous simulations (data stored in files).

Use the simulation command:

> npm run start -- simulation --help

simulation

Start a dht simulation

Options:
  --version              Show version number                           [boolean]
  --help                 Show help                                     [boolean]
  --implementation       ipfs implementation. (ipfs or jsipfs)
                                                             [default: "jsipfs"]
  --nodes, -n            Number of nodes.                          [default: 10]
  --iterations, -i       Number of iterations of putting and getting data.
                                                                  [default: 200]
  --lookup-factor, --lf  Keys replication for the number of nodes.  [default: 2]
  --churn-factor, --cf   Churn per second.                          [default: 2]

According to the above, we can execute the following command to overwrite the default number of nodes:

npm run start -- simulation --nodes 15

Use the statistics comand:

> npm run start -- statistics --help

statistics <filePath>

Show dht simulation statistics

Options:
  --version  Show version number                                       [boolean]
  --help     Show help                                                 [boolean]

Experience

The metrics that can be obtained with this test are the following:

  • lookup average round trip latency
  • success rate

Results

WIP

iptb-dht-test's People

Contributors

vasco-santos avatar

Watchers

 avatar  avatar

Forkers

jonnycrunch

iptb-dht-test's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.