-
-
Notifications
You must be signed in to change notification settings - Fork 95
Description
Goal
Peers attempt to relay contracts that they’re likely to receive requests for. Relaying means that the peer subscribes to contract updates and can then respond to requests for that contract immediately rather than forwarding the request.
Due to the small world network topology, peers are generally more likely to receive requests for contracts close to them.
Overview
- Peers track resource usage per-contract
- Resources include storage, bandwidth, CPU usage, memory
- Cost computed from resources according to cost function
- Peers advertise contracts they are relaying to neighbors, who may decide to relay them too
Cost function
A simple cost function that looks at each resource as a proportion of the total available to the peer and takes the maximum of these proportions:
-
$resource_c$ = contract resource usage -
$resource_t$ = total resource availability
Relay decision
The peer's goal is to relay the contracts that maximize
New contracts will have an unknown
If the peer is exposed to a contract with an estimated
Related Issues
- While this mechanism tracks and managed resource usage per-contract, Peer resource usage balancing #4 describes a parallel mechanism that tracks and manages resource usage per-peer