How the simulation is done

nWaku Version: v0.34.0 branch add-discv5-bw-metric

We will compare the Discv5 bandwidth usage in two different scenarios. One of them is standard relay nodes with discv5, and the other one is the same but also using waku peer exchange protocol.

In order to do this, we will perfom two simulations:

  1. In the first one, we will use 3 nwaku bootstrap nodes with discv5 AND peer exchange. Then we will connect 1000 nwaku relay nodes. 500 of those, will also use the bootstrap nodes as peer-exchange nodes.
  2. In this case, we will use 3 bootstrap nodes with discv5, and 1000 nwaku relay nodes will be connected to them. No peer exchange is used.

Results:

image.png

The bandwidth results match the trend to the ones reported in the Waku discv5 analysis.

At first and taking every node into account, it is true that the difference between the two simulations is not that much. The only place where the difference is “notable” is in discv5-out.

To do a deeper analysis, we can grab the data from only the simulation where we use Discv5 and PX.

Then, we separate the two subset of nodes, obtaining the following plots:

image.png

image.png

Now we do see a difference. It looks like using PX decreasesdiscv5-out usage by ~4x times. Not only this, but it looks like it helps to maintain stable values of discv5-out bandwidth, where only one outlier makes a notable difference, sitting at ~60KB/s.

libp2p bandwidth is also a affected, but in a lower scale.