1pub mod admin;
9pub mod backend_endpoint_allocator;
10pub mod backend_launcher;
11pub mod backend_registry;
12pub mod broadcast;
13pub mod connection;
14pub mod control_socket;
15#[doc(hidden)]
16pub mod deadline_stream;
17pub mod fd_pressure;
18pub mod handoff;
19pub mod handoff_serve;
20pub mod hello_handler;
21pub mod hello_router;
22pub mod idle_coord;
23pub mod instance;
24pub mod metrics;
25pub mod perf_guard;
26pub mod recovery;
27pub mod serve;
28pub mod service_def_loader;
29pub mod spawn_coordinator;
30pub mod spawn_wait;
31pub mod trace_context;
32pub mod version_allow_list;
33
34pub use admin::{
35 handle_admin_connection, serve_one_admin_socket, AdminBackend, AdminConnectionError,
36 AdminFrameError, AdminInodePressure, AdminSnapshot, AdminSpawnBudget, ADMIN_PAYLOAD_PROTOCOL,
37 ADMIN_SCHEMA_VERSION,
38};
39pub use backend_endpoint_allocator::{
40 BackendEndpointAllocator, BackendEndpointAllocatorError, DEFAULT_BACKEND_ENDPOINT_ATTEMPTS,
41};
42pub use backend_launcher::{
43 BackendLaunchError, BackendLaunchRequest, BackendLauncher, CommandBackendLauncher,
44 BACKEND_ENV_ENDPOINT_NAMESPACE, BACKEND_ENV_ENDPOINT_PATH, BACKEND_ENV_INSTANCE,
45 BACKEND_ENV_SERVICE_NAME, BACKEND_ENV_SERVICE_VERSION, BACKEND_ENV_TRACEPARENT,
46 BACKEND_ENV_TRACESTATE,
47};
48pub use backend_registry::{BackendKey, BackendRegistry};
49pub use broadcast::{
50 BroadcastAck, BroadcastBackend, BroadcastBackendResponse, BroadcastFailure,
51 BroadcastFailureReason, BroadcastOperation, BroadcastPolicy, BroadcastResult, BroadcastTimeout,
52 LifecycleBroadcastModel, QuiesceReason, DEFAULT_BROADCAST_ACK_TIMEOUT,
53};
54pub use connection::{
55 handle_hello_connection, handle_hello_connection_with,
56 handle_hello_connection_with_peer_policy, local_socket_name, serve_local_socket_connections,
57 serve_local_socket_connections_with, serve_local_socket_connections_with_peer_policy,
58 serve_local_socket_connections_with_policy, serve_one_local_socket,
59 serve_one_local_socket_with, serve_one_local_socket_with_peer_policy, BrokerConnectionError,
60 HelloResponder, PeerCredentialPolicy,
61};
62pub use control_socket::{
63 handle_control_connection_with_peer_policy,
64 handle_control_connection_with_peer_policy_and_fd_guard,
65 serve_control_socket_connections_with_limit_and_policy,
66 serve_control_socket_connections_with_limit_policy_and_post_hello,
67 serve_control_socket_connections_with_limit_policy_post_hello_and_fd_guard,
68 serve_control_socket_connections_with_policy, ControlSocketConnectionLimit, ControlSocketError,
69 ControlSocketReply,
70};
71pub use fd_pressure::{
72 fd_exhaustion_error_for_tests, is_fd_exhaustion_error, FdPressureConfig, FdPressureDecision,
73 FdPressureGuard, DEFAULT_FD_PRESSURE_RECOVERY_ACCEPTS, DEFAULT_FD_PRESSURE_RETRY_AFTER_MS,
74};
75pub use handoff::{
76 AcknowledgedHandoff, ExpiredHandoff, HandoffAckError, HandoffAckRegistry,
77 HandoffAttemptDecision, HandoffAttemptFailure, HandoffAttemptInputs, HandoffFallbackDecision,
78 HandoffFallbackPolicy, HandoffFallbackReason, HandoffFallbackState, HandoffToken,
79 HandoffTokenError, HandoffTokenStore, HandoffTokenStoreConfig, PendingHandoffBackend,
80 PendingHandoffOverflow, PendingHandoffQueue, PendingHandoffQueueConfig,
81 DEFAULT_HANDOFF_ACK_DEADLINE, DEFAULT_HANDOFF_FAILED_ATTEMPTS_PER_WINDOW,
82 DEFAULT_HANDOFF_FAILED_ATTEMPT_WINDOW, DEFAULT_HANDOFF_TOKEN_COLLISION_ATTEMPTS,
83 DEFAULT_HANDOFF_TOKEN_TTL, DEFAULT_MAX_PENDING_HANDOFFS, DEFAULT_MAX_PENDING_HANDOFF_TOKENS,
84 DEFAULT_PENDING_HANDOFF_TTL, HANDOFF_TOKEN_BYTES,
85};
86pub use handoff_serve::{complete_negotiated_handoff, ServeHandoffContext};
87pub use hello_handler::{
88 HelloHandler, HelloHandlerError, HelloRequest, PeerIdentity, RegisteredBackend,
89};
90pub use hello_router::HelloRouter;
91pub use idle_coord::{
92 BackendIdleCoordinator, BackendIdleDue, BackendIdlePolicy, DEFAULT_BACKEND_IDLE_TIMEOUT,
93};
94pub use instance::{BrokerInstanceError, BrokerInstanceKey};
95pub use perf_guard::{
96 enforce_hello_latency_budget, summarize_hello_latencies, HelloLatencySummary, PerfGuardError,
97 HELLO_P50_BUDGET, HELLO_P99_BUDGET, HELLO_PERF_GUARD_ENV, HELLO_PERF_SAMPLE_COUNT,
98};
99pub use recovery::{
100 BackendRecoveryDecision, BackendRecoveryPolicy, BackendRecoveryRefusalReason,
101 BackendRecoveryState, DEFAULT_RECOVERY_BUDGET_WINDOW, DEFAULT_RECOVERY_RETRY_BACKOFF,
102};
103pub use serve::{
104 build_hello_handler, serve_launching_backends, serve_launching_backends_with_launcher,
105 serve_registered_backend, BrokerLaunchServeConfig, BrokerServeConfig, BrokerServeError,
106};
107pub use service_def_loader::{
108 ensure_service_definition_dir, service_definition_dir, service_definition_path,
109 validate_service_definition_for_service, write_service_definition, ServiceDefinitionError,
110 ServiceDefinitionLoader, SERVICE_DEF_DIR_ENV, SERVICE_DEF_EXTENSION,
111};
112pub use spawn_coordinator::{
113 acquire_spawn_lock, SpawnBeginError, SpawnBudgetConfig, SpawnBudgetSnapshot, SpawnCoordinator,
114 SpawnLockError, SpawnLockFileIdentity, SpawnLockGuard, SpawnOutcome, SpawnPermit,
115 DEFAULT_SPAWN_ATTEMPTS_PER_WINDOW, DEFAULT_SPAWN_BUDGET_WINDOW,
116};
117pub use spawn_wait::{
118 SpawnWaitDecision, SpawnWaitPolicy, SpawnWaitProbe, DEFAULT_SPAWN_WAIT_HARD_CEILING,
119 SPAWN_WAIT_BACKOFF_SEQUENCE,
120};
121pub use trace_context::TraceContext;
122pub use version_allow_list::{check_version_allowed, VersionPolicyBlock};