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

[FEATURE] Support HTTP/2 #215

Closed
arunx2 opened this issue Aug 30, 2022 · 10 comments · Fixed by #330
Closed

[FEATURE] Support HTTP/2 #215

arunx2 opened this issue Aug 30, 2022 · 10 comments · Fixed by #330
Labels
enhancement New feature or request v3.0.0 Issues and PRs related to version v3.0.0

Comments

@arunx2
Copy link

arunx2 commented Aug 30, 2022

Is your feature request related to a problem?

No

What solution would you like?

As the opensearch-java library requires Java 11, we can support HTTP/2 as it is much faster and more reliable than HTTP1. HTTP1 loads a single request for every TCP connection, while HTTP2 avoids network delay by using multiplexing. We can either leverage java HttpClient or square's OkHttp libraries

@arunx2 arunx2 added enhancement New feature or request untriaged labels Aug 30, 2022
@reta
Copy link
Collaborator

reta commented Aug 30, 2022

@arunx2 see please opensearch-project/OpenSearch#4257

@dblock
Copy link
Member

dblock commented Aug 31, 2022

What changes do we need to do in this library after the above was merged? @arunx2 want to contribute? At the least we need to document how to enable HTTP/2.

@reta
Copy link
Collaborator

reta commented Aug 31, 2022

What changes do we need to do in this library after the above was merged?

We basically need to introduce HTTP/2 compatible client transports, there are few ways we could approach that:

Thanks.

@dblock
Copy link
Member

dblock commented Sep 1, 2022

What do you think we should do @reta ?

@reta
Copy link
Collaborator

reta commented Sep 1, 2022

@dblock we could do both :-) I aimed to take on Apache HttpClient 5.x but we could also do PoC on dedicated OpenSearchTransport - those are very independent developments. From the bigger picture, I think Apache HttpClient 5.x has better value propostion since it will cover all supported OpenSearch clients, whereas OpenSearchTransport is limited to opensearch-java only

@wbeckler
Copy link

@reta what do you mean by "all supported OpenSearch clients." I would propose that opensearch-java be the only "supported" java client.

@reta
Copy link
Collaborator

reta commented Dec 23, 2022

@wbeckler apologies for confusion, there are 3 clients right now: RestClient, RestHighLevelClient and opensearch-java. I think what we want is to have OpenSearch and opensearch-java to live independent lives (no inter-dependencies in other words). That leaves us with: RestClient stays (to be used in core internally), RestHighLevelClient is deprecated (and hopefully removed), opensearch-java becomes the official way to connect to OpenSearch clusters from JVM applications.

@reta reta added the v3.0.0 Issues and PRs related to version v3.0.0 label Jan 13, 2023
@reta
Copy link
Collaborator

reta commented Jan 13, 2023

@dblock @wbeckler I think we could close this one: in 3.0.0 HTTP/2 is already supported (except AWS transport since it is based on Apache HttpClient 4.x).

@dblock
Copy link
Member

dblock commented Jan 13, 2023

How about adding in README that this client supports HTTP/2, possibly a section in USER_GUIDE that explains how to use it (does it need to be turned on? does it just work?), and then closing this?

@reta
Copy link
Collaborator

reta commented Jan 16, 2023

Documenting the HTTP/2 support with respect to opensearch-project/OpenSearch#4257

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request v3.0.0 Issues and PRs related to version v3.0.0
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants