You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have two version of he protocol /fuel/req_res/0.0.1 (can return empty response in case of errors) and /fuel/req_res/0.0.2 (returns error codes). When a peer is dialled, one of these two protocols will be agreed for communication. However, the specification of RequestResponse in libp2p-rs does not mention how this is selected.
Suggested solution
One way to solve the problem is to allow /fuel/req_res/0.0.1 to be exchanged only for inbound or outbound connections.
Tradeoffs are discussed below:
If a peer P allows /fuel/req_res/0.0.1 only for inbound connections, then all nodes can safely dial P. However, P can only dial peers that support /fuel/req_res/0.0.2. If the majority of the network did not upgrade to use /fuel/req_res/0.0.2, then P could struggle to establish outbound connections, and will need to downgrade their node version.
If a peer P allows /fuel/req_res/0.0.1 only for outbound connections, then P can safely dial both nodes that support either /fuel/req_res/0.0.1 or /fuel/req_res/0.0.2, as well as nodes that support only /fuel/req_res/0.0.1. On the other hand, peers that support only /fuel/req_res/0.0.1 would not be able to dial P. If the majority of the network upgrades, nodes supporting only /fuel/req_res/0.0.1 could struggle to establish outbound connections, and will need to upgrade their node version.
I am listing both alternatives, but I believe that 2. is probably the best because it incentivises nodes to upgrade the node version.
Acceptance criteria
The P2P request response behaviour is updated to allow /fuel/req_res/0.0.1 either only for inbound or outbound connections.
The text was updated successfully, but these errors were encountered:
Context
We have two version of he protocol
/fuel/req_res/0.0.1
(can return empty response in case of errors) and/fuel/req_res/0.0.2
(returns error codes). When a peer is dialled, one of these two protocols will be agreed for communication. However, the specification ofRequestResponse
inlibp2p-rs
does not mention how this is selected.Suggested solution
One way to solve the problem is to allow
/fuel/req_res/0.0.1
to be exchanged only for inbound or outbound connections.Tradeoffs are discussed below:
If a peer P allows
/fuel/req_res/0.0.1
only for inbound connections, then all nodes can safely dial P. However, P can only dial peers that support/fuel/req_res/0.0.2
. If the majority of the network did not upgrade to use/fuel/req_res/0.0.2
, then P could struggle to establish outbound connections, and will need to downgrade their node version.If a peer P allows
/fuel/req_res/0.0.1
only for outbound connections, then P can safely dial both nodes that support either/fuel/req_res/0.0.1
or/fuel/req_res/0.0.2
, as well as nodes that support only/fuel/req_res/0.0.1
. On the other hand, peers that support only/fuel/req_res/0.0.1
would not be able to dial P. If the majority of the network upgrades, nodes supporting only/fuel/req_res/0.0.1
could struggle to establish outbound connections, and will need to upgrade their node version.I am listing both alternatives, but I believe that 2. is probably the best because it incentivises nodes to upgrade the node version.
Acceptance criteria
The P2P request response behaviour is updated to allow
/fuel/req_res/0.0.1
either only for inbound or outbound connections.The text was updated successfully, but these errors were encountered: