Skip to content

Conversation

@jjteo74
Copy link
Contributor

@jjteo74 jjteo74 commented Oct 7, 2017

Netty 4.1.16 supports Java 9 ALPN, gRPC should take advantage of that to ease deployment (especially on platforms without tcnative and/or openssl).

This PR determines whether Java 9 ALPN and Netty 4.1.16 is available and enables Netty Java 9 ALPN.

@grpc-kokoro
Copy link

Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok for us to run on our infrastructure.

@ejona86
Copy link
Member

ejona86 commented Oct 9, 2017

okay to test

@ejona86
Copy link
Member

ejona86 commented Oct 9, 2017

This is related to #3401 in some ways, because it revamps how we handle Providers.

*/
static boolean isNettyJava9AlpnAvailable() {
try {
Class.forName("io.netty.handler.ssl.Java9SslEngine");
Copy link
Member

Choose a reason for hiding this comment

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

We don't tend to do this sort of thing. We instead just upgrade to the netty that supports the feature we need.

}
});
getApplicationProtocol.invoke(engine);
} catch (Throwable t) {
Copy link
Member

Choose a reason for hiding this comment

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

Could we just catch Exception, or similar? I'd rather not catch every Error and throw it away, as it can hide legitimate problems.

@ejona86
Copy link
Member

ejona86 commented Oct 10, 2017

okay to test

@dapengzhang0 dapengzhang0 added the kokoro:run Add this label to a PR to tell Kokoro the code is safe and tests can be run label Dec 20, 2017
@thelinuxfoundation
Copy link

Thank you for your pull request. Before we can look at your contribution, we need to ensure all contributors are covered by a Contributor License Agreement.

After the following items are addressed, please respond with a new comment here, and the automated system will re-verify.

Regards,
The Linux Foundation CLA GitHub bot

@kokoro-team kokoro-team removed the kokoro:run Add this label to a PR to tell Kokoro the code is safe and tests can be run label Dec 20, 2017
@jjteo74
Copy link
Contributor Author

jjteo74 commented Dec 21, 2017

CLA signed

@ejona86 ejona86 added the kokoro:run Add this label to a PR to tell Kokoro the code is safe and tests can be run label Dec 21, 2017
@kokoro-team kokoro-team removed the kokoro:run Add this label to a PR to tell Kokoro the code is safe and tests can be run label Dec 21, 2017
@ejona86 ejona86 merged commit 3e76bf1 into grpc:master Dec 21, 2017
@ejona86
Copy link
Member

ejona86 commented Dec 21, 2017

Thank you!

@jjteo74 jjteo74 deleted the jdk-alpn branch December 22, 2017 01:32
@ejona86 ejona86 added this to the 1.10 milestone Feb 14, 2018
@lock lock bot locked as resolved and limited conversation to collaborators Jan 19, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants