Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove NPN support from OkHttp #1201

Merged
merged 1 commit into from
Dec 26, 2014

Conversation

nfuller
Copy link
Collaborator

@nfuller nfuller commented Dec 15, 2014

Work in progress.

I see a new failure from a certificate pinning test but I don't
know why. Help solving this would be appreciated.

I also see failures before & after:

  1. A failure from DisconnectTest
    (Apply fix for devices with large socket buffers #1197 may fix that).
  2. A failure from CallTest.doesNotFollow21Redirects_Async (timeout)

The maven changes should be treated with the contempt they deserve.
I mostly removed things I didn't understand and stroked maven until
it stopped squealing. The benchmarks / okcurl changes are a
particular mystery.

Tried with arbitrary versions of openjdk7 and openjdk8 I had
lying around. Behavior was the same across both (i.e. the same
failures).

Work in progress.

I see a new failure from a certificate pinning test but I don't
know why. Help solving this would be appreciated.

I also see failures before & after:
1) A failure from DisconnectTest
(square#1197 may fix that).
2) A failure from CallTest.doesNotFollow21Redirects_Async (timeout)

The maven changes should be treated with the contempt they deserve.
I mostly removed things I didn't understand and stroked maven until
it stopped squealing. The benchmarks / okcurl changes are a
particular mystery.

Tried with arbitrary versions of openjdk7 and openjdk8 I had
lying around. Behavior was the same across both (i.e. the same
failures).
@swankjesse
Copy link
Collaborator

The certificate pinning test is flaky. I need to fix that.

@@ -97,14 +97,15 @@
</build>
<profiles>
<profile>
<id>npn-when-jdk7</id>
<id>alpn-when-jdk7</id>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's no such thing as ALPN support for JDK7. Dropping NPN means dropping SPDY and HTTP/2 from JDK7 completely. I'm okay with that.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you sure?

Based on:
https://webtide.com/jetty-9-2-0-released/

"ALPN is the successor to NPN (the Next Protocol Negotiation) and is implemented for both JDK 7 and JDK 8. ALPN will be used by SPDY and HTTP 2.0 to negotiate the application protocol of a TLS connection."

Various SPDY tests broke on OpenJDK 7 without this, and passed with it.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow, news to me. That's excellent.

@codefromthecrypt
Copy link

So, some sites only support NPN and may not switch SPDY over to ALPN. Also, I don't think twitter responds to ALPN at the moment, so integrations like twitter4j will break. @jpinner am I right on this?

@jpinner
Copy link

jpinner commented Dec 16, 2014

OpenSSL does not currently support ALPN (it's slated for 1.0.2 currently in beta). Twitter (and I suspect other sites running OpenSSL) will not be able to support ALPN until 1.0.2 lands.

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

Successfully merging this pull request may close these issues.

5 participants