Skip to main content

build_connection_services

Function build_connection_services 

Source
pub fn build_connection_services(
    config: &ServerConfig,
) -> Result<Arc<dyn ConnectionServices>, ServerError>
Expand description

Builds the connection-services adapter selected by config’s service profile.

Full builds LiminalConnectionServices (channels, conversations, durable store, dedup cache) exactly as today. WorkerFrontDoor builds WorkerFrontDoorServices, which constructs none of that machinery. This is the single profile-dispatch authority: super::supervisor::ConnectionSupervisor’s config constructor and the standalone runtime’s worker arm both route through it (the runtime’s full arm stays on the explicit LiminalConnectionServices::from_config path because it also needs the shared channel cluster, which the trait object does not expose — that path is guarded full-only at entry).

§Errors

Returns ServerError when the selected adapter cannot be constructed, the configured profile value is not recognised, or the worker-front-door profile is combined with full-only config fields.