[router] add worker abstraction (#7960)

This commit is contained in:
Simo Lin
2025-07-11 20:17:48 -07:00
committed by GitHub
parent 2a2d3478af
commit f2d5c4920e
11 changed files with 960 additions and 410 deletions

View File

@@ -0,0 +1,16 @@
//! Core abstractions for the SGLang router
//!
//! This module contains the fundamental types and traits used throughout the router:
//! - Worker trait and implementations
//! - Error types
//! - Common utilities
pub mod error;
pub mod worker;
// Re-export commonly used types at the module level
pub use error::{WorkerError, WorkerResult};
pub use worker::{
start_health_checker, BasicWorker, HealthChecker, Worker, WorkerCollection, WorkerFactory,
WorkerLoadGuard, WorkerType,
};