Bug 235460 - phttpget: Lacks retry and retry_timeout options
Summary: phttpget: Lacks retry and retry_timeout options
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: CURRENT
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-bugs mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-02-03 13:02 UTC by Ricardo Fraile
Modified: 2019-02-05 18:53 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ricardo Fraile 2019-02-03 13:02:11 UTC
phttpget can be tuned with the following enviromental variables:

HTTP_PROXY
HTTP_PROXY_AUTH
HTTP_USER_AGENT
HTTP_TIMEOUT

It would be nice to have two more:

CONN_RETRY
CONN_TIMEOUT

The HTTP_TIMEOUT is only applied before the connection, so, if for example the dns fails, that request fails with a "phttpget: Could not connect to x.x.x.x".

It would be nice to have the timeout applied at the connection level, and, by the way, a retry to it. That can be solve some issues with freebsd-update.


Thanks,
Comment 1 Ricardo Fraile 2019-02-03 22:19:42 UTC
Sorry, my previous comment has a typo:

The HTTP_TIMEOUT only applies **after** the tcp connection to the remote server. So, if for example the dns fails, the network link have connectivity problems or something related, that request fails quickly with a "phttpget: Could not connect to x.x.x.x" without waiting for the timeout.

It would be nice to have the waiting time applied at the connection level and, by the way, a retry to it. That can solve some issues with freebsd-update and make it more resilience.

Thanks,