Network incentivisation log


#1

In the same spirit as @pedro 's log for nix, I will try to keep regular updates on the progress for the network incentivisation swarm.

Currently we are at the point where we have a proof of concept of the contract we would like to use: https://github.com/status-im/network-incentivisation . This allows nodes to register and votes on other nodes, and the contract will handle membership.
An earlier version of the contract is already used in status-react https://github.com/status-im/status-react/pull/7869 to fetch the initial bootnodes/static nodes/mailservers.

The plan towards an implementation is to have a simple end-to-end implementation and iterate over that, slicing the planning horizontally rather than vertically.

Currently we have a simple enough contract that is usable, and we are now focusing on service nodes.

Upon start up a node will:

  • register (or check if it is registered) with the contract (already implemented)
  • it will post a ping on a whisper channel advertising it’s address (already implemented), which can also be used as a mean of discovery (not for bootstrapping clearly)
  • it will check that other nodes in the contract do the same (already implemented)
  • it will report periodically to the contract and get rewarded if has passed these checks

The plan for this week is to have the nodes report to the contract on the result of the ping checks and be rewarded. Ideally by the end of the week we will be able to have some docker-images that anyone can spin up and they will be registering with the contract, start servicing and get rewarded if behaving correctly.

Once this step is done we will likely focus on improving some of the parts, so adding better checks, better rewarding system, hardening the contract against sybil attack or adding a way for user of the app to contribute to the SNT pool of the contract, but that’s still to be defined.

Research notes here: https://docs.google.com/document/d/10ZVIkYkM8_YwpEbxLX05pIcL8ISuZZvDPV6L_t27xgw/edit#heading=h.b9h1jmb28d8t


#2

Two questions:

  • is there any kind of staking mechanism which would punish a misreporting/spamming node?
  • how are tx costs for contract registration covered?

#3

at this stage of the implementation there’s no staking, nodes will just be removed from the list and will have to re register.

In the future that’s something we discussed, although other implementations get away without staking (DASH), so we haven’t made a decision yet, and we are open to any suggestion.

The price of the transaction (and voting) will have to be covered by the rewarding system (and needs to cover the costs of running a node), and will be paid off in SNT. How much nodes will be rewarded has not been decided, but it will be a function of the number of paying users, the number of nodes and possibly other factors.


#4

Progress as of today 17/04/2019:

  • Managed to get the modified versions of status-go running in a docker container
  • they now register with the contract and listen to whisper pings
  • they vote at regular intervals, checking whether they received pings from other nodes

Next I will verify that the voting removes the misbehaving nodes correctly and add a basic reward system.


#5

Progress as of today 18/04/2019:

  • Tested contract & nodes on goerli testnet, 3 nodes joined the network, 1 went offline, it was removed from the list after a voting session, once back online it was added back to the list of active nodes after a voting session
  • Gas fee are currently fairly low https://goerli.etherscan.io/address/0x61f6d683be830617981ce5c9ea7cd2d1f22cf251 , but requires more testing and higher number of nodes to verify

Next I will work on a basic rewarding system, polish up the implementation and provide a docker image.


#6

Progress as of today 19/04/2019:

  • Added a simplistic reward system and tested with 3 nodes, picked the first formula that came to mind which is: contractBalance / numberOfTransactionMadePerNodePerMonth / nodesToBeRewarded, each node is rewarded every time it votes (and is allowed to vote, which means it’s well behaved). We assume users of the app will be paying in a monthly subscription to use the service (configurable).

With the current settings (1 transaction per 10 minutes, 3 nodes), it would cover the transaction costs if roughly 2 eth are in the contract balance each month. Given 100 paying users that would be around 3 dollars monthly, (0.3 for a 1000 etc). 1 transaction per 10 minutes is also set just for testing, probably 1 per hour is what we’d settle on, but it’s too early stages to think about that.

This is all very rough and just wanted to get a very basic rewarding system, for the more economically inclined of you, suggestions are very welcome (looking at you @barry :slight_smile: )

Next I will polish status-go code and provide a docker image, probably at some point it would be time to formalize the rewarding scheme and make sure it makes sense.


#7

These are exciting steps in the right direction. Would love to see a write up or presentation on the reward system itself and the current design thinking behind it at some point.