From 46eaaed8f14eac6d9ab1fc5c8064d0c38ffbdbcc Mon Sep 17 00:00:00 2001 From: srako Date: Tue, 9 Jun 2026 16:23:13 +0800 Subject: [PATCH] fix(clickhouse): bypass system proxy to prevent connection failure --- crates/dbx-core/src/db/clickhouse_driver.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/crates/dbx-core/src/db/clickhouse_driver.rs b/crates/dbx-core/src/db/clickhouse_driver.rs index 8ed936d88f..dbd77bc1be 100644 --- a/crates/dbx-core/src/db/clickhouse_driver.rs +++ b/crates/dbx-core/src/db/clickhouse_driver.rs @@ -17,7 +17,8 @@ pub struct ChClient { impl ChClient { pub fn new(url: &str, username: Option, password: Option, timeout: Duration) -> Self { - let http = HttpClient::builder().connect_timeout(timeout).build().unwrap_or_else(|_| HttpClient::new()); + let http = + HttpClient::builder().connect_timeout(timeout).no_proxy().build().unwrap_or_else(|_| HttpClient::new()); Self { http, base_url: url.trim_end_matches('/').to_string(), username, password } } @@ -28,7 +29,7 @@ impl ChClient { ca_cert_path: Option<&str>, timeout: Duration, ) -> Result { - let mut builder = HttpClient::builder().connect_timeout(timeout); + let mut builder = HttpClient::builder().connect_timeout(timeout).no_proxy(); if let Some(path) = ca_cert_path.map(str::trim).filter(|path| !path.is_empty()) { let path = expand_cert_path(path); let cert_bytes =