Skip to content
This repository has been archived by the owner on Aug 29, 2024. It is now read-only.

timeout interval option for http request #13

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

tchukuchuk
Copy link

Hi

I need for a project to have a timeout greater then 1min (default timeout for NSMutableURLRequest).

Regards,

Julien

@mattgreen
Copy link
Owner

Have you tried using the existing timeout functionality? Elevate knows what request it's waiting on, and aborts it automatically.

@tchukuchuk
Copy link
Author

Yes, but after some tests it doesn't work.

@mattgreen
Copy link
Owner

That makes sense; you want the request to go longer than one minute, rather than having the task's timeout take a certain amount of time, right?

@tchukuchuk
Copy link
Author

Yes. I have to manage with huge JSON data and it can take a lot of time to be generated...

@mattgreen
Copy link
Owner

OK, that's perfectly reasonable. I hope your server is using async I/O though :).

I'd be glad to merge this if you changed the option name to request_timeout to differentiate it from the regular timeout option.

@tchukuchuk
Copy link
Author

I'm interested by async i/o if you have some documentation :)

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

Successfully merging this pull request may close these issues.

2 participants