From b63debd827dc6b2e23f4e01d9a58d9671fc80804 Mon Sep 17 00:00:00 2001 From: Jesse Wilson Date: Tue, 31 Dec 2019 16:39:08 -0500 Subject: [PATCH] Prepare for release 4.3.0. --- CHANGELOG.md | 42 ++++++++++++++++++++++++++++ README.md | 8 +++--- gradle.properties | 2 +- mockwebserver/README.md | 2 +- okhttp-brotli/README.md | 2 +- okhttp-dnsoverhttps/README.md | 2 +- okhttp-logging-interceptor/README.md | 2 +- okhttp-sse/README.md | 2 +- okhttp-tls/README.md | 2 +- okhttp-urlconnection/README.md | 2 +- 10 files changed, 54 insertions(+), 12 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 26fa98893..3fe504f25 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,48 @@ Change Log ========== +## Version 4.3.0 + +_2019-12-31_ + + * Fix: Degrade HTTP/2 connections after a timeout. When an HTTP/2 stream times out it may impact + the stream only or the entire connection. With this fix OkHttp will now send HTTP/2 pings after + a stream timeout to determine whether the connection should remain eligible for pooling. + + * Fix: Don't call `EventListener.responseHeadersStart()` or `responseBodyStart()` until bytes have + been received. Previously these events were incorrectly sent too early, when OkHttp was ready to + read the response headers or body, which mislead tracing tools. Note that the `responseFailed()` + event always used to follow one of these events; now it may be sent without them. + + * New: Upgrade to Kotlin 1.3.61. + + * New: Match any number of subdomains with two asterisks in `CertificatePinner`. For example, + `**.squareup.com` matches `us-west.www.squareup.com`, `www.squareup.com` and `squareup.com`. + + * New: Share threads more aggressively between OkHttp's HTTP/2 connections, connection pool, + web sockets, and cache. OkHttp has a new internal task runner abstraction for managed task + scheduling. In your debugger you will see new thread names and more use of daemon threads. + + * Fix: Don't drop callbacks on unexpected exceptions. When an interceptor throws an unchecked + exception the callback is now notified that the call was canceled. The exception is still sent + to the uncaught exception handler for reporting and recovery. + + * Fix: Un-deprecate `MockResponse.setHeaders()` and other setters. These were deprecated in OkHttp + 4.0 but that broke method chaining for Java callers. + + * Fix: Don't crash on HTTP/2 HEAD requests when the `Content-Length` header is present but is not + consistent with the length of the response body. + + * Fix: Don't crash when converting a `HttpUrl` instance with an unresolvable hostname to a URI. + The new behavior strips invalid characters like `"` and `{` from the hostname before converting. + + * Fix: Undo a performance regression introduced in OkHttp 4.0 caused by differences in behavior + between Kotlin's `assert()` and Java's `assert()`. (Kotlin always evaluates the argument; Java + only does when assertions are enabled.) + + * Fix: Honor `RequestBody.isOneShot()` in `HttpLoggingInterceptor`. + + ## Version 4.2.2 _2019-10-06_ diff --git a/README.md b/README.md index 7b9b420c3..c1f54b43a 100644 --- a/README.md +++ b/README.md @@ -99,10 +99,10 @@ Releases Our [change log][changelog] has release history. -The latest release is available on [Maven Central](https://search.maven.org/artifact/com.squareup.okhttp3/okhttp/4.2.2/jar). +The latest release is available on [Maven Central](https://search.maven.org/artifact/com.squareup.okhttp3/okhttp/4.3.0/jar). ```kotlin -implementation("com.squareup.okhttp3:okhttp:4.2.2") +implementation("com.squareup.okhttp3:okhttp:4.3.0") ``` Snapshot builds are [available][snap]. [R8 and ProGuard][r8_proguard] rules are available. @@ -113,10 +113,10 @@ MockWebServer OkHttp includes a library for testing HTTP, HTTPS, and HTTP/2 clients. -The latest release is available on [Maven Central](https://search.maven.org/artifact/com.squareup.okhttp3/mockwebserver/4.2.2/jar). +The latest release is available on [Maven Central](https://search.maven.org/artifact/com.squareup.okhttp3/mockwebserver/4.3.0/jar). ```kotlin -testImplementation("com.squareup.okhttp3:mockwebserver:4.2.2") +testImplementation("com.squareup.okhttp3:mockwebserver:4.3.0") ``` License diff --git a/gradle.properties b/gradle.properties index f1a5f6559..7e393baf8 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,7 +1,7 @@ org.gradle.jvmargs='-Dfile.encoding=UTF-8' GROUP=com.squareup.okhttp3 -VERSION_NAME=4.3.0-SNAPSHOT +VERSION_NAME=4.3.0 POM_URL=https://github.com/square/okhttp POM_SCM_URL=https://github.com/square/okhttp diff --git a/mockwebserver/README.md b/mockwebserver/README.md index b6d2443dc..591904f9b 100644 --- a/mockwebserver/README.md +++ b/mockwebserver/README.md @@ -142,7 +142,7 @@ server.setDispatcher(dispatcher); ### Download ```kotlin -testImplementation("com.squareup.okhttp3:mockwebserver:4.2.1") +testImplementation("com.squareup.okhttp3:mockwebserver:4.3.0") ``` ### License diff --git a/okhttp-brotli/README.md b/okhttp-brotli/README.md index 6ed3f1537..2e8c78c20 100644 --- a/okhttp-brotli/README.md +++ b/okhttp-brotli/README.md @@ -14,7 +14,7 @@ OkHttpClient client = new OkHttpClient.Builder() ``` ```kotlin -implementation("com.squareup.okhttp3:okhttp-brotli:4.2.1") +implementation("com.squareup.okhttp3:okhttp-brotli:4.3.0") ``` [1]: https://github.com/google/brotli diff --git a/okhttp-dnsoverhttps/README.md b/okhttp-dnsoverhttps/README.md index 638671f38..c2d0fca13 100644 --- a/okhttp-dnsoverhttps/README.md +++ b/okhttp-dnsoverhttps/README.md @@ -7,5 +7,5 @@ API is not considered stable and may change at any time. ### Download ```kotlin -testImplementation("com.squareup.okhttp3:okhttp-dnsoverhttps:4.2.1") +testImplementation("com.squareup.okhttp3:okhttp-dnsoverhttps:4.3.0") ``` diff --git a/okhttp-logging-interceptor/README.md b/okhttp-logging-interceptor/README.md index 5f0f51374..09283b926 100644 --- a/okhttp-logging-interceptor/README.md +++ b/okhttp-logging-interceptor/README.md @@ -37,7 +37,7 @@ Download -------- ```kotlin -implementation("com.squareup.okhttp3:logging-interceptor:4.2.1") +implementation("com.squareup.okhttp3:logging-interceptor:4.3.0") ``` diff --git a/okhttp-sse/README.md b/okhttp-sse/README.md index cf64bc1f8..49fb8ed56 100644 --- a/okhttp-sse/README.md +++ b/okhttp-sse/README.md @@ -7,5 +7,5 @@ API is not considered stable and may change at any time. ### Download ```kotlin -testImplementation("com.squareup.okhttp3:okhttp-sse:4.2.1") +testImplementation("com.squareup.okhttp3:okhttp-sse:4.3.0") ``` diff --git a/okhttp-tls/README.md b/okhttp-tls/README.md index 52a4bfc32..4ffd57cdb 100644 --- a/okhttp-tls/README.md +++ b/okhttp-tls/README.md @@ -227,7 +227,7 @@ Download -------- ```kotlin -implementation("com.squareup.okhttp3:okhttp-tls:4.2.1") +implementation("com.squareup.okhttp3:okhttp-tls:4.3.0") ``` [held_certificate]: http://square.github.io/okhttp/4.x/okhttp-tls/okhttp3.tls/-held-certificate/ diff --git a/okhttp-urlconnection/README.md b/okhttp-urlconnection/README.md index 56064181c..f613a754a 100644 --- a/okhttp-urlconnection/README.md +++ b/okhttp-urlconnection/README.md @@ -6,5 +6,5 @@ This module integrates OkHttp with `Authenticator` and `CookieHandler` from `jav ### Download ```kotlin -testImplementation("com.squareup.okhttp3:okhttp-urlconnection:4.2.1") +testImplementation("com.squareup.okhttp3:okhttp-urlconnection:4.3.0") ```