[model-gateway] Avoid MCP Server Initialization Issue (#15065)
This commit is contained in:
@@ -660,9 +660,8 @@ impl McpManager {
|
||||
|
||||
// Create HTTP client with proxy support
|
||||
let client = if token.is_some() {
|
||||
let mut builder = reqwest::Client::builder()
|
||||
.timeout(Duration::from_secs(30))
|
||||
.connect_timeout(Duration::from_secs(10));
|
||||
let mut builder =
|
||||
reqwest::Client::builder().connect_timeout(Duration::from_secs(10));
|
||||
|
||||
// Apply proxy configuration using proxy.rs helper
|
||||
if let Some(proxy_cfg) = proxy_config {
|
||||
|
||||
@@ -95,9 +95,7 @@ pub fn apply_proxy_to_builder(
|
||||
/// # Returns
|
||||
/// A configured reqwest::Client or error
|
||||
pub fn create_http_client(proxy_config: Option<&McpProxyConfig>) -> McpResult<reqwest::Client> {
|
||||
let mut builder = reqwest::Client::builder()
|
||||
.timeout(Duration::from_secs(30))
|
||||
.connect_timeout(Duration::from_secs(10));
|
||||
let mut builder = reqwest::Client::builder().connect_timeout(Duration::from_secs(10));
|
||||
|
||||
// Apply MCP-specific proxy if configured
|
||||
if let Some(proxy_cfg) = proxy_config {
|
||||
|
||||
Reference in New Issue
Block a user