[model-gateway] fix imports and delete unused code (#14911)
This commit is contained in:
@@ -97,8 +97,6 @@ pub struct DiscoverMcpInventoryStep;
|
||||
#[async_trait]
|
||||
impl StepExecutor for DiscoverMcpInventoryStep {
|
||||
async fn execute(&self, context: &mut WorkflowContext) -> WorkflowResult<StepResult> {
|
||||
use rmcp::{service::RunningService, RoleClient};
|
||||
|
||||
let config_request: Arc<McpServerConfigRequest> =
|
||||
context.get_or_err("mcp_server_config")?;
|
||||
let app_context: Arc<AppContext> = context.get_or_err("app_context")?;
|
||||
@@ -143,8 +141,6 @@ pub struct RegisterMcpServerStep;
|
||||
#[async_trait]
|
||||
impl StepExecutor for RegisterMcpServerStep {
|
||||
async fn execute(&self, context: &mut WorkflowContext) -> WorkflowResult<StepResult> {
|
||||
use rmcp::{service::RunningService, RoleClient};
|
||||
|
||||
let config_request: Arc<McpServerConfigRequest> =
|
||||
context.get_or_err("mcp_server_config")?;
|
||||
let app_context: Arc<AppContext> = context.get_or_err("app_context")?;
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
//! 3. RemoveFromWorkerRegistry - Remove workers from worker registry
|
||||
//! 4. UpdateRemainingPolicies - Update cache-aware policies for remaining workers
|
||||
|
||||
use std::{collections::HashSet, sync::Arc};
|
||||
use std::{collections::HashSet, sync::Arc, time::Duration};
|
||||
|
||||
use async_trait::async_trait;
|
||||
use tracing::{debug, info};
|
||||
@@ -239,8 +239,6 @@ impl StepExecutor for UpdateRemainingPoliciesStep {
|
||||
|
||||
/// Create a worker removal workflow definition
|
||||
pub fn create_worker_removal_workflow() -> WorkflowDefinition {
|
||||
use std::time::Duration;
|
||||
|
||||
WorkflowDefinition::new("worker_removal", "Remove worker from router")
|
||||
.add_step(
|
||||
StepDefinition::new(
|
||||
|
||||
@@ -269,9 +269,6 @@ pub enum WorkflowError {
|
||||
|
||||
#[error("Context value not found: {0}")]
|
||||
ContextValueNotFound(String),
|
||||
|
||||
#[error("Context value type mismatch: {0}")]
|
||||
ContextTypeMismatch(String),
|
||||
}
|
||||
|
||||
pub type WorkflowResult<T> = Result<T, WorkflowError>;
|
||||
|
||||
Reference in New Issue
Block a user