sql icon indicating copy to clipboard operation
sql copied to clipboard

[BUG] JDBC driver incorrectly reports it's user-agent and version

Open MaxKsyunz opened this issue 3 years ago • 1 comments

What is the bug? JDBC driver sets User-Agent HTTP parameter to openes-jdbc/1.0.0.0.

The version is wrong and the moniker should probably be opensearch-jdbc.

What is the expected behavior?

  1. String moniker to identifier JDBC driver as an OpenSearch client (opensearch-jdbc maybe?)
  2. User-Agent version to match the version of the jar file (set in build.gradle).

Do you have any additional context? Version is set here. The comment says "keep in sync with gradle." It clearly hasn't been -- it'd be great if it can be kept in sync automatically.

MaxKsyunz avatar Oct 08 '22 06:10 MaxKsyunz

Code related: https://github.com/opensearch-project/sql/blob/2.x/sql-jdbc/src/main/java/org/opensearch/jdbc/internal/Version.java#L12

dai-chen avatar Oct 11 '22 17:10 dai-chen

Fixed in #941

Yury-Fridlyand avatar Nov 09 '22 17:11 Yury-Fridlyand