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
Is your feature request related to a problem? Please describe.
The fetchp does not allow users to retry failed requests, which can cause problems with data transfers. Adding a request retry feature would make transfers more reliable and successful.
Describe the solution you'd like
The retry property in the FetchpRequestInit interface allows users to specify whether or not to retry failed requests, and how many times to retry them. It can be set to a boolean value, a number, or a custom function that determines whether or not to retry a request based on the error that occurred.
If retry is set to true, the fetchp will automatically retry failed requests once.
If retry is set to a number, the fetchp will automatically retry failed requests that number of times.
If retry is set to a custom function, the fetchp will pass the error that occurred to the function, and will only retry the request if the function returns true.
Additional context
The retryDelay function calculates the time to wait before retrying based on the attemptIndex, which starts at 0 for the first attempt. It can be used to increase the delay with each retry attempt to prevent overwhelming the server.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
The fetchp does not allow users to retry failed requests, which can cause problems with data transfers. Adding a request retry feature would make transfers more reliable and successful.
Describe the solution you'd like
The retry property in the FetchpRequestInit interface allows users to specify whether or not to retry failed requests, and how many times to retry them. It can be set to a boolean value, a number, or a custom function that determines whether or not to retry a request based on the error that occurred.
retry
is set to true, the fetchp will automatically retry failed requests once.retry
is set to a number, the fetchp will automatically retry failed requests that number of times.retry
is set to a custom function, the fetchp will pass the error that occurred to the function, and will only retry the request if the function returnstrue
.Additional context
The
retryDelay
function calculates the time to wait before retrying based on theattemptIndex
, which starts at 0 for the first attempt. It can be used to increase the delay with each retry attempt to prevent overwhelming the server.The text was updated successfully, but these errors were encountered: