1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
//! # solti
//!
//! Feature and namespace façade for the modular Solti SDK.
//! It contains no runtime logic.
//! Features select component crates and expose them under stable namespaces.
//!
//! Use this crate when an agent binary needs several SDK components.
//! Depend on a component crate directly when one component is enough.
//!
//! ## Start Here
//!
//! 1. Choose the capabilities required by the binary.
//! 2. Enable their `solti` features.
//! 3. Import each component through its namespace.
//! 4. Build and own the application runtime.
//!
//! All features are disabled by default.
//! Higher-level features enable their required lower layers.
//!
//! ## Feature Flow
//!
//! ```text
//! application features
//! ▼
//! solti
//! ├── model ─────────────► solti-model + JSON Schema
//! ├── runner ────────────► solti-runner + model + taskvisor
//! ├── core ──────────────► solti-core + runner + taskvisor/controller
//! ├── exec-* ────────────► solti-exec integrations
//! ├── api-* ─────────────► solti-api transports and adapters
//! ├── discover-* ────────► solti-discover transports
//! ├── observe-* ─────────► solti-observe integrations
//! ├── prometheus-* ──────► solti-prometheus integrations
//! └── tls ───────────────► solti-tls
//! ```
//!
//! Component crates never depend on this façade.
//! The façade preserves their ownership boundaries.
//!
//! ## Choose Features
//!
//! | Need | Feature family |
//! |------------------------------|-------------------------|
//! | Resource types and schemas | `model` |
//! | Runner registration | `runner` |
//! | Desired-state supervision | `core` |
//! | Host process controls | `exec-host-process` |
//! | Subprocess execution | `exec-subprocess` |
//! | Container engine boundary | `exec-container` |
//! | Native containerd 2.x | `exec-containerd` |
//! | Seccomp host process filter | `exec-seccomp` |
//! | HTTP task API | `api-http` |
//! | gRPC task API | `api-grpc` |
//! | Core API adapter | `api-core-adapter` |
//! | gRPC server TLS | `api-grpc-tls` |
//! | HTTP discovery | `discover-http` |
//! | gRPC discovery | `discover-grpc` |
//! | Discovery TLS | `discover-tls` |
//! | Logging integrations | `observe-*` |
//! | Prometheus integrations | `prometheus-*` |
//! | Shared TLS types | `tls` |
//! | Taskvisor integrations | `taskvisor-*` |
//!
//! `exec-seccomp` enables the low-level host process filter.
//! Combine it with `exec-subprocess` to filter subprocess attempts.
//! `exec-container` exposes the engine-neutral container runner.
//! `exec-containerd` adds the native containerd 2.x adapter.
//!
//! `api-http` and `api-grpc` expose transports.
//! They do not enable `solti-core`.
//! Add `api-core-adapter` when the API delegates to `core::SupervisorApi`.
//!
//! `discover-http` and `discover-grpc` select the outbound discovery transport.
//! They do not select the task API exposed by the agent.
//!
//! `model` includes the `solti-model/schema` feature.
//! The `full` feature enables the complete standard integration set.
//!
//! ## Namespaces
//!
//! | Namespace | Component crate |
//! |----------------|-----------------------|
//! | `api` | `solti-api` |
//! | `core` | `solti-core` |
//! | `discover` | `solti-discover` |
//! | `exec` | `solti-exec` |
//! | `model` | `solti-model` |
//! | `observe` | `solti-observe` |
//! | `prometheus` | `solti-prometheus` |
//! | `runner` | `solti-runner` |
//! | `taskvisor` | `taskvisor` |
//! | `tls` | `solti-tls` |
//!
//! A namespace exists only when its owning feature is enabled.
//! Re-exported APIs keep their component-crate paths below that namespace.
//!
//! ## Quick Start
//!
//! Enable only the components used by the binary:
//!
//! ```toml
//! [dependencies]
//! solti = { version = "0.0.3", features = [
//! "api-core-adapter",
//! "api-http",
//! "exec-subprocess",
//! ] }
//! ```
//!
//! Use the canonical namespaces:
//!
//! ```rust,no_run
//! # #[cfg(all(feature = "core", feature = "exec-subprocess"))]
//! # async fn build() -> Result<solti::core::SupervisorApi, Box<dyn std::error::Error>> {
//! use solti::core::SupervisorApi;
//! use solti::exec::subprocess::register_subprocess_runner;
//! use solti::runner::RunnerRouter;
//!
//! let mut router = RunnerRouter::new();
//! register_subprocess_runner(&mut router, "default")?;
//!
//! let supervisor = SupervisorApi::builder(router).start().await?;
//! # Ok(supervisor)
//! # }
//! ```
/// Compiles the runnable Rust code blocks in `README.md` as doctests.
;
/// Task API types from `solti-api`.
pub use solti_api as api;
/// Desired-state supervisor types from `solti-core`.
pub use solti_core as core;
/// Agent discovery types from `solti-discover`.
pub use solti_discover as discover;
/// Execution integrations from `solti-exec`.
pub use solti_exec as exec;
/// Resource and domain types from `solti-model`.
pub use solti_model as model;
/// Observability integrations from `solti-observe`.
pub use solti_observe as observe;
/// Prometheus integrations from `solti-prometheus`.
pub use solti_prometheus as prometheus;
/// Runner contracts and routing from `solti-runner`.
pub use solti_runner as runner;
/// Task supervision types from `taskvisor`.
pub use taskvisor;
/// TLS and mTLS configuration types from `solti-tls`.
pub use solti_tls as tls;