Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added timeout feature for requests. #42

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

d4rk-d4nph3
Copy link

@d4rk-d4nph3 d4rk-d4nph3 commented Jun 27, 2020

Some of the sites I was testing was taking too much time by CloudFail. I traced out the culprit which was the Exception thrown:

Failed to establish a new connection: [Errno 60] Operation timed out'))

which occurs due to default timeout behavior used in requests. So, the process would be stuck on a particular subdomain request for a long time then resume after the exception is thrown.

This PR adds an optional timeout argument chosen by the user and also a default timeout of 5 sec if not given.

Hence, In this way CloudFail won't be stuck on any subdomain and also users will have the option to alter the timeout rather than the rigid hardcoded value.

Also, this makes the runtime of CloudFail to be near deterministic if everything goes right.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant