Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
During mining process, there is several request to get a previous transaction or a the while tranaction chain.
Request and mining process have some timeout of 3sec.
But transactions can have a maximum size of 3MB and if the node connection is low (especially in upload), send 3MB can take more time than 3 sec
So to avoid te timeout behavior for low connection speed, we can dynamically adapt the timeout depending on the maximum request size expected.
Fixes poart of #425
Type of change
How Has This Been Tested?
To simulate low connection, we can update the connection.ex file with this on line 299:
and this in top of the file
To test with big transaction size we can use Aeweb cli
Transaction will take a lot of time to be validated, but will not fall in timeout due to low speed connection
Checklist: