mirror of
https://github.com/openai/codex.git
synced 2026-11-27 23:31:09 +00:00
Reuse route-aware clients for OpenAI file uploads (#35717)
## What changed - Store a request-logging-disabled `RouteAwareClientPool` in session services and use it for file creation, blob upload, and finalization requests. - Preserve the existing system-root fallback for transport-default proxy routes, and emit a warning event when that fallback is used. - Remove the direct `reqwest` dependency from `codex-api` now that uploads use the shared HTTP abstraction. ## Testing - Add coverage for completing multiple uploads through a shared client pool. GitOrigin-RevId: 01842415cad2d349a6bd3869abb3332e8110ebce
This commit is contained in:
1 parent
2494d939cf
commit
899539c03a
11 files changed
+228
-104
No files matched your search
@@ -28,6 +28,7 @@ use codex_extension_api::ExtensionData;
|
||||
use codex_extension_api::ExtensionDataInit;
|
||||
use codex_extension_api::ExtensionRegistry;
|
||||
use codex_hooks::Hooks;
|
||||
use codex_http_client::RouteAwareClientPool;
|
||||
use codex_login::AuthManager;
|
||||
use codex_mcp::McpRuntime;
|
||||
use codex_models_manager::manager::SharedModelsManager;
|
||||
@@ -56,6 +57,8 @@ pub(crate) struct SessionServices {
|
||||
pub(crate) show_raw_agent_reasoning: bool,
|
||||
pub(crate) exec_policy: Arc<ExecPolicyManager>,
|
||||
pub(crate) auth_manager: Arc<AuthManager>,
|
||||
/// Upload-only clients shared across turns without logging signed blob URLs.
|
||||
pub(crate) openai_file_upload_client_pool: RouteAwareClientPool,
|
||||
pub(crate) models_manager: SharedModelsManager,
|
||||
pub(crate) session_telemetry: SessionTelemetry,
|
||||
pub(crate) tool_approvals: Mutex<ApprovalStore>,
|
||||
|
||||
Reference in new issue
Block a user