Support Apps tool catalogs without shared snapshots (#57572)

## What changed

- Add `ConnectorRuntimeManager::without_shared_snapshot()` to keep connector catalogs local to each client and disable disk caching.
- Use the thread's own Apps discovery when snapshot sharing is disabled, preserving its catalog across turns.
- Expose `apps_tools_from_mcp_client()` to read a ready, unshared Apps client's tools without starting or waiting for discovery.

## Testing

Extend coverage for shared-cache eligibility and verify that an unshared thread waits for its own Apps discovery and uses its own tools on successive model requests, even when a peer finishes discovery first.

GitOrigin-RevId: d57ddacaede047e67c09d378c86c1aa3577ca56f
This commit is contained in:
bkotsopoulos
2026-10-27 22:01:13 +00:00
committed by copyberry
parent 6562117a81
commit d03a6e1a6a
10 changed files with 330 additions and 26 deletions
+11
View File
@@ -294,6 +294,17 @@ impl CodexThread {
&self.session.services.thread_extension_data
}
/// Returns tools from this thread’s ready, unshared Apps MCP client.
/// Returns an empty list if the client is absent, still starting, or uses
/// a shared catalog. Does not start or wait for discovery.
pub async fn apps_tools_from_mcp_client(&self) -> Vec<codex_mcp::ToolInfo> {
self.session
.services
.mcp_runtime
.apps_tools_from_mcp_client()
.await
}
/// Returns data captured by the named running turn, not newer thread settings.
pub async fn current_turn_extension_data<T>(&self, expected_turn_id: &str) -> Option<Arc<T>>
where