Skip to content

fix: 118 - query not using proxy #119

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

Merged
merged 6 commits into from
Feb 24, 2025
Merged

fix: 118 - query not using proxy #119

merged 6 commits into from
Feb 24, 2025

Conversation

karel-rehor
Copy link
Contributor

@karel-rehor karel-rehor commented Feb 13, 2025

Closes #118

Proposed Changes

  • extract proxy argument when creating _query_api and use it as new field for QueryApi object
  • Use this object to set generic Flight client options

Checklist

  • CHANGELOG.md updated
  • Rebased/mergeable
  • A test has been added if appropriate
  • Tests pass
  • Commit messages are conventional
  • Sign CLA (if not already signed)

Copy link

codecov bot commented Feb 18, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 60.45%. Comparing base (5739de0) to head (43ccac5).
Report is 7 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #119      +/-   ##
==========================================
+ Coverage   60.35%   60.45%   +0.10%     
==========================================
  Files          33       33              
  Lines        2048     2051       +3     
==========================================
+ Hits         1236     1240       +4     
+ Misses        812      811       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@karel-rehor
Copy link
Contributor Author

Manual test with cluster seems to work

    client = InfluxDBClient3(
        host="https://influxdb3-clustered-swan.brambora.zona-b.eu:443",
        token="************",
        org="Bonitoo",
        database="Ephemera",
        proxy="http://localhost:10000",
        debug=True,
        verify_ssl=False,
        ssl_ca_cert="/home/pipin/bonitoo/qa/temp/influxdb3-python-issues/ssl/cert.pem"
    )

And envoy log shows...

envoy-1  | [2025-02-19T13:45:18.608Z] "CONNECT - HTTP/1.1" 200 DC 1101 1762 1870 - "-" "-" "526d15be-9b06-4f74-abf4-97ebdbf5535b" "influxdb3-clustered-swan.brambora.zona-b.eu:443" "44.231.79.1:443"
envoy-1  | [2025-02-19T13:45:19.240Z] "CONNECT - HTTP/1.1" 200 DC 1158 6350 1238 - "-" "grpc-httpcli/0.0" "ebbe32b9-6d40-4982-bd06-da4c9ee4557d" "influxdb3-clustered-swan.brambora.zona-b.eu:443" "44.231.79.1:443"

So marking PR "PR ready for review"

@karel-rehor karel-rehor marked this pull request as ready for review February 19, 2025 13:52
Copy link
Contributor

@alespour alespour left a comment

Choose a reason for hiding this comment

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

LGTM

@karel-rehor
Copy link
Contributor Author

Final manual tests with envoy proxy to clustered server with self-signed certificates pass. Ready to merge.

envoy-1  | [2025-02-24T15:39:39.829Z] "CONNECT - HTTP/1.1" 200 DC 1101 1762 1804 - "-" "-" "ba8a82c2-ab2b-452a-8dbd-7e3ebeb387d3" "influxdb3-clustered-swan.brambora.zona-b.eu:443" "35.160.5.45:443"
envoy-1  | [2025-02-24T15:39:40.529Z] "CONNECT - HTTP/1.1" 200 DC 1179 6670 1104 - "-" "grpc-httpcli/0.0" "9fbcbff7-17cd-4e68-b984-e965993394bf" "influxdb3-clustered-swan.brambora.zona-b.eu:443" "35.160.5.45:443"
envoy-1  | [2025-02-24T15:41:06.413Z] "CONNECT - HTTP/1.1" 200 DC 1066 1762 1784 - "-" "-" "45755c16-6b4f-484a-978c-f935d31c69dd" "influxdb3-clustered-swan.brambora.zona-b.eu:443" "35.160.5.45:443"
envoy-1  | [2025-02-24T15:41:07.058Z] "CONNECT - HTTP/1.1" 200 DC 1120 5684 1139 - "-" "grpc-httpcli/0.0" "1acd6d56-686c-425e-a3b0-46f1483261ac" "influxdb3-clustered-swan.brambora.zona-b.eu:443" "35.160.5.45:443"

@karel-rehor karel-rehor merged commit 8028386 into main Feb 24, 2025
14 checks passed
@karel-rehor karel-rehor deleted the fix/118-grpc-proxy branch February 24, 2025 15:43
@karel-rehor karel-rehor added this to the 0.11.0 milestone Feb 27, 2025
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.

client not using proxy - grpc
3 participants