pub struct ConfigFile {
pub primary_project: Option<PathBuf>,
pub runtime: RuntimeFileConfig,
pub broker: BrokerFileConfig,
pub server: ServerFileConfig,
pub telemetry: TelemetryFileConfig,
pub output: OutputFileConfig,
}Expand description
Merged view of the config file(s). All fields optional: an absent field defers to the env var, then the built-in default.
Fields§
§primary_project: Option<PathBuf>Default Lake project for calls without a project= argument. Kept for
backward compatibility with the original primary_project-only file.
runtime: RuntimeFileConfig§broker: BrokerFileConfig§server: ServerFileConfig§telemetry: TelemetryFileConfig§output: OutputFileConfigImplementations§
Source§impl ConfigFile
impl ConfigFile
Sourcepub fn load(cwd: &Path) -> Self
pub fn load(cwd: &Path) -> Self
Load and merge the home and project-local files. Home is the base; the
nearest lean-host-mcp.toml at or above cwd overlays it per key. A
missing file contributes nothing; a malformed file is logged and
skipped. Never fails: the worst case is an empty config (env + defaults).
Trait Implementations§
Source§impl Debug for ConfigFile
impl Debug for ConfigFile
Source§impl Default for ConfigFile
impl Default for ConfigFile
Source§fn default() -> ConfigFile
fn default() -> ConfigFile
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ConfigFile
impl<'de> Deserialize<'de> for ConfigFile
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for ConfigFile
impl RefUnwindSafe for ConfigFile
impl Send for ConfigFile
impl Sync for ConfigFile
impl Unpin for ConfigFile
impl UnsafeUnpin for ConfigFile
impl UnwindSafe for ConfigFile
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more