Skip to content

Conversation

@reta
Copy link
Contributor

@reta reta commented Oct 18, 2022

Signed-off-by: Andriy Redko [email protected]

Description

When using JDK 16+, the org.apache.hc.core5.http.ParseException: Invalid protocol version is being thrown.

Issues Resolved

N/A

Check List

  • New functionality includes testing.
    • All tests pass
  • New functionality has been documented.
    • New functionality has javadoc added
  • Commits are signed per the DCO using --signoff
  • Commit changes are listed out in CHANGELOG.md file (See: Changelog)

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@reta reta requested a review from a team as a code owner October 18, 2022 18:57
@reta reta force-pushed the fix.jdk.17.tls.factory branch from 803855c to a9ed595 Compare October 18, 2022 18:58
@github-actions
Copy link
Contributor

Gradle Check (Jenkins) Run Completed with:

@github-actions
Copy link
Contributor

Gradle Check (Jenkins) Run Completed with:

@github-actions
Copy link
Contributor

Gradle Check (Jenkins) Run Completed with:

Copy link
Member

@dblock dblock left a comment

Choose a reason for hiding this comment

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

This is all the same setTlsDetailsFactory code. Want to refactor the default implementation for TlsStrategy into a helper?

CHANGELOG.md Outdated
- Fix decommission status update to non leader nodes ([4800](https://github.com/opensearch-project/OpenSearch/pull/4800))
- Fix recovery path for searchable snapshots ([4813](https://github.com/opensearch-project/OpenSearch/pull/4813))
- Fix bug in AwarenessAttributeDecommissionIT([4822](https://github.com/opensearch-project/OpenSearch/pull/4822))
- Addressing 'org.apache.hc.core5.http.ParseException: Invalid protocol version' under JDK 16+ ([#4827](https://github.com/opensearch-project/OpenSearch/pull/4827))
Copy link
Member

Choose a reason for hiding this comment

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

Can just say Fix

HttpAsyncClientBuilder httpClientBuilder) {
final TlsStrategy tlsStrategy = ClientTlsStrategyBuilder.create()
.setSslContext(sslContext)
// See please https://issues.apache.org/jira/browse/HTTPCLIENT-2219
Copy link
Member

Choose a reason for hiding this comment

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

Nit: just say "see ..."

@reta
Copy link
Contributor Author

reta commented Oct 19, 2022

This is all the same setTlsDetailsFactory code. Want to refactor the default implementation for TlsStrategy into a helper?

I don't know to be honest (I don't see much value out of it), that's not the kind of helper one wants to make public (since it is used in a few modules and packages), more like workaround

@reta reta added the v3.0.0 Issues and PRs related to version 3.0.0 label Oct 19, 2022
@github-actions
Copy link
Contributor

Gradle Check (Jenkins) Run Completed with:

@github-actions
Copy link
Contributor

Gradle Check (Jenkins) Run Completed with:

@andrross andrross merged commit 3af46ae into opensearch-project:main Oct 19, 2022
ashking94 pushed a commit to ashking94/OpenSearch that referenced this pull request Nov 7, 2022
… version' under JDK 16+ (opensearch-project#4827)

* Addressing 'org.apache.hc.core5.http.ParseException: Invalid protocol version' under JDK 16+

Signed-off-by: Andriy Redko <[email protected]>

* Addressing code review comments

Signed-off-by: Andriy Redko <[email protected]>

Signed-off-by: Andriy Redko <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

v3.0.0 Issues and PRs related to version 3.0.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants