> On Jul 30, 2015, at 11:04 , Jens Alfke <j...@mooseyard.com> wrote: > > >> On Jul 29, 2015, at 5:55 PM, Rick Mann <rm...@latencyzero.com> wrote: >> >> It seems the only workaround is to make the timeoutIntervalForRequest very >> long, too, which is gross, as a single request may legitimately time out in >> a short amount of time, but the large set of tasks could take much longer to >> run through. > > I’ve recently seen the argument made that most network requests should > _never_ time out: it’s better to let the user decide when something’s taking > too long. In some cases they may be prepared to wait ten minutes for a server > to respond while downloading some crucial file, while in other cases they’ll > give up in ten seconds. Just give the user something like a Stop button to > cancel the operation. > > The exception would be where an operation is completely invisible to the > user, but even in that case it might be better to put up an alert like “The > automatic backup is stalled because the server isn’t responding. Do you want > to keep trying or give up?”
I tend to agree, although this is from the perspective of the user. Perhaps a network operation can time out, and the code can silently retry it. Maybe "no timeouts" and "timeout and retry" are equivalent. I still think the current NSURLSession behavior isn't correct. Perhaps it needs a third timeout value representing what I think it should do. Or a fourth for "all session tasks." But the current behavior seems to be the least useful of the bunch. -- Rick Mann rm...@latencyzero.com _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com