Skip to content

Commit a8a2f4a

Browse files
committed
feat(gateway): web admin version-probe parity and drop unused mcpmux-mcp
Un-stub check_server_version / check_all_server_versions onto ServerVersionProbeService. Delete the orphaned mcpmux-mcp crate; ClientPool had no callers. Signed-off-by: crimsonsunset <jsangio1@gmail.com>
1 parent ae445a1 commit a8a2f4a

15 files changed

Lines changed: 42 additions & 889 deletions

File tree

AGENTS.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,7 @@ mcp-mux/
1616
├── crates/
1717
│ ├── mcpmux-core/ # Domain entities, repository traits, service layer, EventBus
1818
│ ├── mcpmux-gateway/ # Axum gateway — routing, OAuth refresh, FeatureSet filtering
19-
│ ├── mcpmux-storage/ # SQLite + AES-256-GCM field encryption + OS keychain
20-
│ └── mcpmux-mcp/ # MCP protocol client wrapper (rmcp SDK)
19+
│ └── mcpmux-storage/ # SQLite + AES-256-GCM field encryption + OS keychain
2120
├── packages/ui/ # Shared UI components (`@mcpmux/ui`)
2221
├── schemas/ # JSON Schemas surfaced in the Monaco editor
2322
└── tests/ # Rust integration, TS unit (vitest), desktop E2E (WDIO), web E2E (playwright)

CLAUDE.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,12 +66,11 @@ pnpm typecheck # TypeScript type checking (recursive)
6666

6767
### Rust Crate Architecture
6868

69-
The Cargo workspace has 4 library crates + 1 app crate + 1 test crate:
69+
The Cargo workspace has 3 library crates + 1 app crate + 1 test crate:
7070

7171
- **mcpmux-core** (`crates/mcpmux-core/`) - Domain layer: entities (Space, InstalledServer, FeatureSet, Client), repository traits, domain services, application services with event emission, and the central EventBus
7272
- **mcpmux-gateway** (`crates/mcpmux-gateway/`) - Axum HTTP gateway: routes MCP calls to correct servers, manages OAuth 2.1+PKCE token refresh, filters tools/resources/prompts based on FeatureSets, per-client access key auth, server connection pooling
7373
- **mcpmux-storage** (`crates/mcpmux-storage/`) - SQLite persistence with AES-256-GCM field-level encryption via ring, typed credential rows (per-token encryption), DPAPI key storage on Windows (`keychain_dpapi.rs`), OS keychain on macOS/Linux via keyring crate, zeroize for secure memory clearing
74-
- **mcpmux-mcp** (`crates/mcpmux-mcp/`) - MCP protocol client management using rmcp SDK
7574
- **apps/desktop/src-tauri** - Tauri 2 app shell, Tauri commands, system tray, deep-link handler (`mcpmux://`)
7675
- **tests/rust** - Integration test crate
7776

Cargo.lock

Lines changed: 0 additions & 26 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ members = [
44
"apps/desktop/src-tauri",
55
"crates/mcpmux-core",
66
"crates/mcpmux-gateway",
7-
"crates/mcpmux-mcp",
87
"crates/mcpmux-storage",
98
"tests/rust",
109
]
@@ -78,7 +77,6 @@ http-body-util = "0.1"
7877
# Internal crates (path-only for workspace)
7978
mcpmux-core = { path = "crates/mcpmux-core" }
8079
mcpmux-gateway = { path = "crates/mcpmux-gateway" }
81-
mcpmux-mcp = { path = "crates/mcpmux-mcp" }
8280
mcpmux-storage = { path = "crates/mcpmux-storage" }
8381

8482
[profile.release]

README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -242,8 +242,7 @@ mcp-mux/
242242
├── crates/
243243
│ ├── mcpmux-core/ # Domain logic
244244
│ ├── mcpmux-gateway/ # HTTP gateway, OAuth, routing
245-
│ ├── mcpmux-storage/ # SQLite + encryption + OS keychain
246-
│ └── mcpmux-mcp/ # MCP protocol
245+
│ └── mcpmux-storage/ # SQLite + encryption + OS keychain
247246
├── packages/ui/ # Shared UI components
248247
└── tests/ # Unit, integration, E2E tests
249248
```

THIRD_PARTY_LICENSES

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ Generated via `cargo license`
2828
- openssl
2929
- sync_wrapper
3030
- tao
31-
- mcpmux-core, mcpmux-gateway, mcpmux-mcp, mcpmux-storage (internal)
31+
- mcpmux-core, mcpmux-gateway, mcpmux-storage (internal)
3232

3333
### Apache-2.0 OR MIT (Dual Licensed)
3434
- tokio, tokio-macros, tokio-util (async runtime)

apps/desktop/src-tauri/src/services/admin_server.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -515,6 +515,7 @@ pub async fn start_admin_server_if_enabled(
515515
gateway_port_service: app_state.gateway_port_service.clone(),
516516
server_discovery: app_state.server_discovery.clone(),
517517
settings_repository: app_state.settings_repository.clone(),
518+
installed_server_repository: app_state.installed_server_repository.clone(),
518519
workspace_binding_repository: app_state.workspace_binding_repository.clone(),
519520
machine_repository: Arc::new(SqliteMachineRepository::new(app_state.database())),
520521
inbound_client_repository: Arc::new(mcpmux_storage::InboundClientRepository::new(

crates/mcpmux-gateway/src/admin/bridge_context.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ use std::sync::Arc;
55

66
use mcpmux_core::{
77
AppSettingsRepository, ApplicationServices, FeatureSetRepository, GatewayPortService,
8-
MachineRepository, ServerDiscoveryService, ServerFeatureRepository, ServerLogManager,
9-
SpaceBaseDirRepository, SpaceBuiltinConfigRepository, SpaceService,
8+
InstalledServerRepository, MachineRepository, ServerDiscoveryService, ServerFeatureRepository,
9+
ServerLogManager, SpaceBaseDirRepository, SpaceBuiltinConfigRepository, SpaceService,
1010
WorkspaceAppearanceRepository, WorkspaceBindingRepository,
1111
};
1212
use mcpmux_storage::InboundClientRepository;
@@ -35,6 +35,7 @@ pub struct AdminBridgeCtx {
3535
pub gateway_port_service: Arc<GatewayPortService>,
3636
pub server_discovery: Arc<ServerDiscoveryService>,
3737
pub settings_repository: Arc<dyn AppSettingsRepository>,
38+
pub installed_server_repository: Arc<dyn InstalledServerRepository>,
3839
pub workspace_binding_repository: Arc<dyn WorkspaceBindingRepository>,
3940
pub machine_repository: Arc<dyn MachineRepository>,
4041
pub inbound_client_repository: Arc<InboundClientRepository>,

crates/mcpmux-gateway/src/admin/command_bridge/write.rs

Lines changed: 29 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ use crate::admin::command_bridge::read::{
2121
to_workspace_appearance_response, to_workspace_binding_response,
2222
};
2323
use crate::admin::command_bridge::space::{self, UpdateSpaceInput};
24+
use crate::services::ServerVersionProbeService;
2425

2526
const LOCAL_ICON_PREFIX: &str = "local:workspace-icons/";
2627
const WORKSPACE_ICON_DIR: &str = "workspace-icons";
@@ -1246,19 +1247,40 @@ pub async fn revoke_oauth_client_feature_set(
12461247
.await
12471248
}
12481249

1250+
fn version_probe(ctx: &AdminBridgeCtx) -> ServerVersionProbeService {
1251+
ServerVersionProbeService::new(
1252+
ctx.installed_server_repository.clone(),
1253+
ctx.settings_repository.clone(),
1254+
ctx.services.event_bus.clone(),
1255+
)
1256+
}
1257+
12491258
/// Probe npm/PyPI for a single installed server package update.
12501259
pub async fn check_server_version(
1251-
_ctx: &AdminBridgeCtx,
1252-
_body: ServerConnectionBody,
1260+
ctx: &AdminBridgeCtx,
1261+
body: ServerConnectionBody,
12531262
) -> Result<Value> {
1254-
// ponytail: version probing lands in Phase 5
1255-
Err(anyhow!("Server version checking not yet available"))
1263+
let result = version_probe(ctx)
1264+
.probe_server(&body.space_id, &body.server_id)
1265+
.await?;
1266+
Ok(json!({
1267+
"spaceId": result.space_id,
1268+
"serverId": result.server_id,
1269+
"currentVersion": result.current_version,
1270+
"latestVersion": result.latest_version,
1271+
"updateAvailable": result.update_available,
1272+
"checkedAt": result.checked_at.to_rfc3339(),
1273+
}))
12561274
}
12571275

12581276
/// Probe all notify/auto package-managed servers for available updates.
1259-
pub async fn check_all_server_versions(_ctx: &AdminBridgeCtx) -> Result<Value> {
1260-
// ponytail: version probing lands in Phase 5
1261-
Err(anyhow!("Server version checking not yet available"))
1277+
pub async fn check_all_server_versions(ctx: &AdminBridgeCtx) -> Result<Value> {
1278+
let summary = version_probe(ctx).probe_all().await?;
1279+
Ok(json!({
1280+
"checked": summary.checked,
1281+
"updatesAvailable": summary.updates_available,
1282+
"checkedAt": summary.checked_at.to_rfc3339(),
1283+
}))
12621284
}
12631285

12641286
const META_TOOLS_REQUIRE_APPROVAL_KEY: &str = "meta_tools.require_approval";

crates/mcpmux-mcp/Cargo.toml

Lines changed: 0 additions & 27 deletions
This file was deleted.

0 commit comments

Comments
 (0)