Commit Graph

8 Commits (ac1763f2c7f0bbb16a7ff57211ae041e1241353a)

Author SHA1 Message Date
Visa Putkinen 84785ec473 Fix hang when upload receives HTTP 500
When an uploading PUT request got a HTTP 500 as reponse, grive hanged
forever inside libcurl. This was because the File parameter was not
rewound to 0 position on retry. The XmlResponse had to be cleared as
well.

Rewinding the File and clearing the XmlResponse were not enough to fix
the problem, because when retrying after 500, HTTP 410 Gone or 412
Precondition failed is often received, and CheckHttpResponse would throw
an exception that crashes grive. Therefore, I implemented a retry logic
to Resource::Upload that retries the whole upload transaction if 410 or
412 was received.
2013-11-27 00:15:24 +02:00
Visa Putkinen 645bb2e7d4 Add delay before auth token refresh
This is sometimes necessary to prevent too frequent requests.
2013-11-27 00:15:15 +02:00
Nestal Wan 738435837b using DataStream instead of Receiveable 2013-04-29 23:47:32 +08:00
Nestal Wan 755ee1c9ad new qt gui 2013-04-29 23:47:32 +08:00
Nestal Wan 5a0c6ae56e don't throw in CurlAgent for all HTTP errors (#82) 2012-07-26 01:25:44 +08:00
Nestal Wan 51e42914f3 refreshing the token if HTTP 401 is returned (#83) 2012-07-23 16:00:21 +08:00
Nestal Wan c6a1c47d40 added retry on HTTP 500 & 503 (#82) 2012-07-20 00:50:40 +08:00
Nestal Wan 28e8012ca5 added AuthAgent, a wrapper around http agent 2012-07-20 00:39:36 +08:00