archethic-node
archethic-node copied to clipboard
Adjust the timeout of coordinator waiting context
Describe the problem you discovered
This happens when a transaction have been sent to 3 nodes. The transaction was transmitted faster to the coordinator than the cross validation nodes. The latest ones, started to the process the transaction after the timeout of context's waiting from the coordinator. (This timeout ensures the liveness for cross validators from the coordinator's point of view)
Hence, the transaction was dropped by the coordinator, resulting in a notification to the welcome node and the client about a timeout. However, under the scenes, the cross validators started to switch coordinator, because this one didn't reply to their late context's messages. After that, the transaction was validated by themselves (which is a good behavior, preventing fault tolerance).
But the client is not aware, as the Graphql's subscritipion was closed after the error notification.
Describe the solution you'd like
We should increase this timeout to accept some network faults and latencies, but still be able to reason about nodes which doesn't reply with a certain timeframe.
Epic
#306
This should have been fixed by https://github.com/archethic-foundation/archethic-node/pull/1483