1
0
mirror of https://github.com/square/okhttp.git synced 2026-01-27 04:22:07 +03:00
Commit Graph

242 Commits

Author SHA1 Message Date
jwilson
22e45daefd Recover from failed flushes and closes too. 2013-04-17 00:25:53 -04:00
Jake Wharton
4950e75a5b Merge pull request #148 from square/jwilson/sync_disklrucache
Update to the latest DiskLruCache.
2013-04-15 14:42:11 -07:00
jwilson
6ed0f2c2cb Update to the latest DiskLruCache.
Includes everything thru 8842981cbcfe20eb4721c0a2c867fa9a18233062
2013-04-15 17:39:52 -04:00
Jesse Wilson
56738401eb Merge pull request #147 from square/marcelo/fix_style
Fix style
2013-04-15 08:02:11 -07:00
Marcelo Cortes
242be7e578 Fix style 2013-04-15 09:42:22 -04:00
Jesse Wilson
1ef7e6913e Merge pull request #146 from square/jwilson/sync_idle_time
Synchronize access to idleStartTimeNs.
2013-04-11 15:24:40 -07:00
jwilson
12b35d6a62 Synchronize access to idleStartTimeNs.
See https://github.com/square/okhttp/issues/145
2013-04-11 14:53:27 -07:00
Marcelo Cortes
c8917a1b1f Merge pull request #144 from square/jwilson/copyright
Restore Apache copyright header to ConnectionPool.
2013-04-10 15:55:23 -07:00
jwilson
ba31ada6f3 Restore Apache copyright header to ConnectionPool.
This file was derived from AOSP's HttpConnectionPool.java, which
was derived from Apache Harmony's HttpConnectionManager.java.
2013-04-10 15:51:45 -07:00
Jake Wharton
94d9d88c90 Merge pull request #143 from square/marcelo/fix_copyright
Fixed copyrights
2013-04-10 15:49:02 -07:00
Marcelo Cortes
56c190404b Fixed copyrights 2013-04-10 15:27:02 -07:00
Marcelo Cortes
e4c41a5c39 Merge pull request #142 from square/marcelo/failed_routes
RouteSelector tries previously failed routes last #106
2013-04-10 15:20:23 -07:00
Marcelo Cortes
1ece746c81 RouteSelector tries previously failed routes last #106 2013-04-10 15:19:36 -07:00
Jake Wharton
9bed92fa26 Merge pull request #141 from square/jwilson/empty_header
Be more strict about outgoing request headers.
2013-04-09 13:04:57 -07:00
jwilson
923eb55473 Be more strict about outgoing request headers.
We now forbid empty header names, and '\0' characters in names
or values. This should improve the experience for SPDY users,
who will see the failure when they add the header rather than
when the request is made.
2013-04-09 12:53:51 -07:00
Jake Wharton
af61be6fd9 Merge pull request #140 from square/jwilson/empty_header
Allow empty header values
2013-04-09 11:16:08 -07:00
jwilson
d7ed3f8c44 Allow empty header values
This tracks an AOSP change by Brian Carlstrom.
Change-Id: I78bb07a93d527eda6aaee6e986be39a68e0a02f4
2013-04-09 08:17:30 -07:00
Jesse Wilson
ae4a84a73d Merge pull request #138 from square/jwilson/recoverystream
FaultRecoveringOutputStream.
2013-04-08 17:17:16 -07:00
jwilson
4e3da9d430 FaultRecoveringOutputStream.
This is the first step in a change that'll permit the underlying
socket stream to change out-from-under-you while you're uploading
POST data to a server.

It'll recover from failures writing the request body that occur
within the first N bytes, where N will be determined by the number
of bytes that can be written without positive confirmation.

See https://github.com/square/okhttp/issues/137
2013-04-08 13:00:02 -06:00
Jake Wharton
ace08e9f28 Merge pull request #136 from square/jwilson/froyo
Don't use APIs that Froyo doesn't have.
2013-03-31 11:57:47 -07:00
jwilson
d704709fa9 Don't use APIs that Froyo doesn't have. 2013-03-31 14:33:01 -04:00
Jake Wharton
30cb962d9d Merge pull request #135 from square/jwilson/flush
Track DiskLruCache.flush change.
2013-03-30 15:24:56 -07:00
jwilson
e1d6d3d030 Track DiskLruCache.flush change.
Current DiskLruCache version is ebbb058e8226d2c5531bb2d66ff4d41d6edd366c
2013-03-30 18:24:28 -04:00
Jesse Wilson
fe280d5813 Merge pull request #134 from square/jwilson/latest_disklrucache
Use the latest DiskLruCache in OkHttp.
2013-03-30 14:59:53 -07:00
jwilson
c0df29ac0b Use the latest DiskLruCache in OkHttp. 2013-03-30 17:59:14 -04:00
Jake Wharton
595b9a750c Merge pull request #133 from square/jwilson/cache_api
Tidy the public API for HttpResponseCache.
2013-03-30 13:22:58 -07:00
jwilson
621bfd7710 Tidy the public API for HttpResponseCache.
This moves the special internal-only methods into a new interface,
OkHttpResponseCache. I jump through some hoops to expose only the
java.net.ResponseCache interface in the API.
2013-03-30 15:56:11 -04:00
Jake Wharton
2595af3862 Merge pull request #132 from square/jwilson/public_api_for_cache
Provide a non-internal API to the response cache.
2013-03-27 12:27:00 -07:00
jwilson
988f519754 Provide a non-internal API to the response cache.
Currently this is roughed in. Before I can close issue 131
I need to clean up the docs and verify that we aren't leaking
public APIs.

https://github.com/square/okhttp/issues/131
2013-03-27 14:11:26 -04:00
Jake Wharton
2e5f36d339 Merge pull request #130 from square/jw/apache
Add Apache HttpClient implementation which maps to OkHttp.
2013-03-27 00:29:23 -07:00
Jake Wharton
d60c084b99 Add Apache HttpClient implementation which maps to OkHttp.
Refs #17.
2013-03-26 13:27:46 -04:00
Jesse Wilson
36b6980e23 Merge pull request #129 from square/jw/modules
Move library into a module. Introduce sample module with simple GitHub c...
2013-03-25 21:27:02 -07:00
Jake Wharton
7ccbf48838 Move library into a module. Introduce sample module with simple GitHub client. 2013-03-25 20:04:51 -07:00
Jesse Wilson
ba2b7432cb Merge pull request #127 from narayank/master
Guard against invalid name value block headers.
2013-03-15 07:39:21 -07:00
Narayan Kamath
2f1629d593 Merge branch 'master' of https://github.com/narayank/okhttp 2013-03-12 17:10:27 +00:00
Narayan Kamath
780a2cbd70 Guard against invalid name value block headers.
If a badly behaved server sends us a negative number
of name value blocks, we should throw an IOException and
not a RTE (which will be thrown when we try to construct an
ArrayList with a negative size).
2013-03-12 16:56:28 +00:00
Jesse Wilson
0100630551 Merge pull request #125 from iosphere/android-41739
Add support for following HTTP 307 temporary redirects.
2013-02-28 12:48:05 -08:00
Jesse Wilson
9c330d70a7 Merge pull request #126 from square/edenman/seriously-froyo
Fix froyo bug: no more descendingIterator
2013-02-27 16:23:16 -08:00
Eric Denman
f373e2d6e5 Fix froyo bug: no more descendingIterator 2013-02-27 16:19:47 -08:00
Christopher Orr
0665b628fa Add support for following HTTP 307 temporary redirects.
Fixes Android bug 41739.
2013-02-27 19:09:12 +01:00
Jesse Wilson
f24072ec6b Merge pull request #124 from square/jw/eviction
Add evictAll method to connection pool.
2013-02-27 08:59:17 -08:00
Jake Wharton
220b5f9a3b Add evictAll method to connection pool.
Closes #104.
2013-02-27 08:31:04 -08:00
Jesse Wilson
91db9299c3 Merge pull request #123 from square/jw/test-fixes
Ensure we test the correct connection instance.
2013-02-21 01:20:01 -08:00
Jesse Wilson
1c5990e4c1 Merge pull request #122 from square/jw/response-source-header
Add new synthetic header for determining response source.
2013-02-21 01:19:28 -08:00
Jake Wharton
5a4c7c34af Add new synthetic header for determining response source. 2013-02-21 00:30:26 -08:00
Jake Wharton
2aaf055b3d Ensure we test the correct connection instance. 2013-02-21 00:19:44 -08:00
Jesse Wilson
4b7e0b733f Merge pull request #121 from narayank/master
Fix a null pointer exception in SpdyTransport#makeReusable
2013-02-20 09:08:59 -08:00
Narayan Kamath
36c0a8048a Fix NPE in SpdyTransport#makeReusable 2013-02-20 15:43:12 +00:00
Jesse Wilson
65ebcbdea5 Merge pull request #120 from square/jwilson/protocolredirects
Optionally follow redirects from HTTPS to HTTP and vice versa.
2013-02-18 22:35:37 -08:00
jwilson
38575673e4 Optionally follow redirects from HTTPS to HTTP and vice versa.
The API is imperfect because HttpURLConnection doesn't expose
any SSL information, and because HttpsURLConnection won't necessarily
have a secure final request.
2013-02-18 04:18:53 -05:00